How do I move a physics object

0 favourites
  • 2 posts
From the Asset Store
This is a code so you can see the same skin on all screens (peers). Each peer gets a skin, in addition to 4 directions t
  • Hello, I've got a simple question :

    I can move an object like "on key is down => move forward 2pixels" so it move smoothly.

    My problem is when I release the keycode, I want the object to move down, say 2pixels/tic or ms during 50px or 1 second, but I cannot find a way to do it, can someone help me?

    (the object is a physics object)

    cannot link capx yet :/

    Thanks for replying and helping me.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • instead of using 'move forward', Give your Sprite directional movement behavior.

    Then use 'on key A is down' > Simulate Moving Left

    Then use 'on key D is down' > Simulate Moving Right

    You can set the max speed of the object as you like.

    Use the physics behavior to enable and disable gravity as you need. Use the 'on key is down' 'on key is released'

    to trigger

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)