dop2000's Recent Forum Activity

  • You can do this with Chipmunk physics, but I don't know if this addon has been ported for C3.

    With standard Physics behavior you can probably use an invisible sprite with several frames, each with a different collision polygon. Add physics behavior and change frames when necessary. Pin your main sprite to it.

  • -160 is the same as 200 degrees.

    angle() expression returns negative values for angles between 180 and 360.

  • Try "For each" loop.

    System: For each Buttons
     Mouse is over Buttons -> Buttons Set animation "On"
     Else -> Buttons Set animation "off"
    

    to insert images, upload an image, then use "img" tag:

    [img=5432]
  • Try this:

    Turret set angle to clamp(angle(Turret.x, Turret.y, Touch.x, Touch.y), -160, -20)

  • Why don't you use gravity? With gravity it will look much more natural.

    This can also be done with Bullet behavior, it also has gravity setting.

    You can slow down or stop the ball when it collides with the floor. For example:

    Ball on collision with Floor -> Ball set Bullet speed to (Ball.Bullet.Speed/2)

  • You can make all these objects global, then when player selects a group of objects, destroy all other objects and change layout. Remaining objects will be transferred to the new layout.

    Alternatively, you need to save the list of selected objects in an array/dictionary and then re-create them in the new layout from the saved data.

    Read about families and containers, they may make the job much easier.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Save your table in CSV format, then use one of the online tools to convert it to JSON. Here is the first result from google.

    Then you'll need to manually modify JSON for Construct format. Here are a few examples:

    {"c2dictionary":true,"data":{"a":409,"b":473,"h":643,"f":313,"l":394}}

    {"c2array":true,"size":[4,1,1],"data":[[[73]],[[55]],[[76]],[[40]]]}

    .

    Note, that if you are going to load JSON directly from a string, you'll have to double all quotation marks:

    MyArray load from JSON string "{""c2array"":true,""size"":[4,1,1],""data"":[[[73]],[[55]],[[76]],[[40]]]}"
    
  • There are a couple of plugins that you can probably use:

    construct.net/forum/extending-construct-2/work-in-progress-addons-30/plugin-jcw-trace-raycast-112436

    construct.net/forum/extending-construct-2/addons-29/behavior-rex-light-78888

    But I would stick to Bullet. If you make the collision polygon shape close to circle, it should bounce off corners pretty well. Add a rough, low-fps animation to it and you'll get what you want.

  • Your mistake is that you think X is the horizontal axis, but in 2D arrays it's vertical. So rows are X or Width, and columns are Y or Height.

    You need to update your code like this:

    Note that XValue should start with -1

  • You can save the ID and UID of the first door in local variables, then pick all doors, and then pick a door with same ID and a different UID. Something like this:

    Player on collision with Door
     variable doorID=0
     variable sourceDoorUID=0
     
     -> Set doorID to Door.ID
     -> Set sourceDoorUID to Door.UID
    
     System Pick all Door
    
     Door compare variable ID=doorID
     Door pick by unique ID NOT equal to sourceDoorUID
     ----> Player set position to Door
    
    
    
  • You can set animation frame for each instance in the layout editor (on the left panel). No code is required.

    If you need to change frames during runtime, you can identify each instance by IID/UID as Maverick1912 suggested. Or add some instance variable, for example "Type". Then you can use an event like

    System For each Sprite 
     Sprite.Type=1 -> set animation frame to 5
     Sprite.Type=2 -> set animation frame to 10
    
  • Your JSON data is intended for an array, so you need to load it into an array.

    Dictionary JSON should look like this:

    {"c2dictionary":true,"data":{"a":123,"b":456,"c":789}}

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