Physics/animation issue?

0 favourites
  • 5 posts
From the Asset Store
3 pixel charaters with over 8 animations each + animations with a gun
  • Problem Description

    Physics force for movement only is applied once every animation finish or stop

    Attach a Capx

    https://drive.google.com/open?id=0B4n8l_KPrCyQUkRIMVJ1T3RiSGs

    Description of Capx

    simple animation the runs continuous try using WASD to move it around and it will skip

    Steps to Reproduce Bug

    • import animation
    • apply physics and make animation repeat when finished
    • apply physics force to angle at keyboard (wasd) or position to mouse

    Observed Result

    sprite will skip once every animation finished or stop during animation play it pauses

    Expected Result

    smooth semi Newtonian physics for space ship like movement(inertia etc)

    Affected Browsers

    • Chrome: (YES
    • FireFox: N/A
    • Internet Explorer: N/A
    • Edge: Yes

    Operating System and Service Pack

    Windows 10 all latest updates

    Construct 2 Version ID

    R239 64bit

  • yes its an interesting one....not quite sure myself..

    nice gimble

    I have tried a few things but the problem remains..... ..maybe some one else has an idea..?

    will have to look at it again tomorrow..for now I am stumped

  • anybody else encounter this issue? dosn't anybody know a fix? I cant continue on this game till its fixed:(

  • anybody else encounter this issue? doesn't anybody know a fix? I cant continue on this game till its fixed:(

    Yeah I did, all I can give you are 2 workarounds but no real fix for this issue.

    1. Use a separate "collider" sprite and set game character position accordingly

    Basically an additional sprite which only has a single frame. You will have to set the collisions and add the physics behavior to this sprite, you basically base all your game mechanics on this "collider" sprite, while your actual animated game character is used for visual feedback. (I'm using this method for my physics based game mechanics.)

    2. Try to use the 3rd party plugin "Chipmunk Physics" (LINK)

    This behavior comes with a lot of advantages that you can read by clicking on the link above.

    I'm not sure if that works well with animations but I think it should.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Closing as won't fix - you should not use animated Physics objects. The Physics behavior treats a change of frame as destroying the physics body and teleporting a new one in its place (to take in to account changing collision poly, size, origin etc). Therefore animating objects keeps destroying the physics body you're applying force to.

    The workaround is to use a non-animated invisible physics body and then place the animating spite on top.

    I think that's not mentioned in the documentation, so I should probably add that somewhere...

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