dop2000's Recent Forum Activity

  • Do they work in other (non-construct) games? Do they work in preview? Have you tried NWjs export?

  • You can add Touch object to the project and use Touch.AngleAt(0) and Touch.SpeedAt(0) expressions. They should work when dragging with mouse too. For example, this is dragging to the right:

    Sprite is dragging
    Touch.AngleAt(0) is within 30 degrees of 0
    Touch.SpeedAt(0)>100 
    
  • I had the same issue and I've seen several people mentioning this - editor.construct.net/r317-2/ opens r327 instead.

    In my case it resolved itself somehow.

    You can try clearing browser cache/data.

  • + FileChooser: On changed
    -> Sprite: Load image from FileChooser.FileURLAt(0) (Resize to image size, cross-origin anonymous)
    

    The image will replace the current frame. So you need to set the right animation and frame in your sprite first.

  • It's hard to troubleshoot without the project file. "For each devices" with the condition where you check for ObjectTypeName should work.

    Where and when do you run this event? Instances in C3 are not created immediately, sometimes you need to wait until the end of the tick to be able to access them from other events. If this is the case, add "Wait 0" before running that event.

    I suggest debugging such issues using Browser Log action. For example:

    For each devices : Browse Log "Iterating devices UID=" & devices.UID
    
    .. devices.ObjectTypeName="foo" : "Picked device:"&devices.ObjectTypeName
    
    etc.
    

    Open the browser console and check the messages there.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • This is the fourth time you are asking the same question. Please read this post:

    construct.net/en/forum/construct-3/how-do-i-8/best-help-tips-forum-139528

  • There is an official example in C3:

    editor.construct.net

  • You do not have permission to view this post

  • I don't understand the problem. You can still pick family instances by object name. And use Family.ImagepointX/Y

  • I am using dictionaries.AsJSON inside of arrays, and then the arrays are stored as JSON inside another array

    It's a very inefficient way to store data, like you said escaping " with backslashes is probably making 80% of the entire string. I don't think compressing the string with zlib will magically reduce its size from 30KB to 1KB. I suggest you change the way the data is stored. Use just one array or JSON. Don't nest JSONs inside of JSONs inside of JSONs.

    In this game many thousands of objects are stored in a single JSON file. I'm using a string like this, which is pretty compact and easy to read:

    {
     "island1": {
     "objects": [
     {"o": "Tree,animationname","x": 100,"y": 200},
     {"o": "Rock,animationname","x": 405,"y": 112}
     ]
     },
     "island2": {...}
    }
    
  • It depends on how levels are built in your game and what information you need to store in the string. For example, if there are three object types players can place on a 50x30 grid, then you can encode the entire grid into a string 1500 characters long, where letters A-C represent an object and a dot represents an empty cell:

    A.A...BAC.....A.B..CBB.ABC.CCB....

    Another totally different approach is to upload the string to an online service like Pastebin.com

    When you upload a string, you get a unique URL, which can be used to download this string. So people can share and exchange URLs in Discord, instead of full strings.

    Both uploading and downloading from Pastebin can be done with AJAX.

  • One thought is to put all my sprites into a family and then trying pick last created [family]

    This is the right method, I use it all the time.

    I tried doing a for loop from 0 to family.AllChildCount but this only returned a single iteration of the loop. It is not properly counting (or detecting) the family's children.

    AllChildCount expression is related to hierarchies. Family "children" are usually called members, and unfortunately there is no way to get a list of all family members in events. You can make your own list of members, for example with an array.

dop2000's avatar

dop2000

Member since 26 May, 2016

Twitter
dop2000 has 257 followers

Connect with dop2000

Trophy Case

  • 8-Year Club
  • Entrepreneur Sold something in the asset store
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Forum Wizard Made 5,000 posts in the forums
  • Forum Unicorn Made 10,000 posts in the forums
  • x5
    Popular Game One of your games has over 1,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • Enduring Visitor Visited Construct.net 90 days in a row
  • Unrelenting Visitor Visited Construct.net 180 days in a row
  • Continuous Visitor Visited Construct.net 365 days in a row
  • RTFM Read the fabulous manual
  • x3
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • x13
    Great Comment One of your comments gets 3 upvotes
  • Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

28/44
How to earn trophies