How do I create a vertically correct death animation

0 favourites
  • 8 posts
From the Asset Store
3 pixel charaters with over 8 animations each + animations with a gun
  • Hi.

    I have a 2d platformer with a character that has a sine death animation - very mario-like. This works great as long as the character dies on the "bottom" of the layout. But when the character has jumped up on some platforms and dies there, the sine animation isnt suitable because it doesnt go all the way to the bottom of the screen. I´ve tried playing around with the sine settings, but can´t find anything that works in general everywhere on the layout. I cant find any tutorials or alike that covers this subject.

    Maybe sine isn´t the way to go?

    Hope you can help

    Thanks!

  • Do you mean this animation?

    Subscribe to Construct videos now

    It's easy to do with Bullet behavior.

    Set angle of motion=-90

    speed=1000

    gravity=2000

    And, probably disable collisions.

  • EXACTLY what I was looking for. Thanks!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Uuuhm... one more question!

    The first time this die animation plays, it is perfect. But when I respawn the player (by setting the player´s X and Y and resetting it´s health), and the player dies again he get´s shut off with a high speed in top of the layoyt. It´s like if the bullet has not been reset. I´m disabling the bullet after the animation.

    If I use the System > Restart layout, the animation plays fine the second time, but I cannot do that because of game state issues.

  • Looks like the bullet behavior is still enabled.

    Try to disable it in the same event where you respawning the player.

  • Thanks alot for your answer!

    Well I´ve tried to disable it again after I respawn, but the problem remains the same. This is my event:

    Any idea? :/

  • Oh, sorry, I misread your previous comment.

    You need to add "Set bullet speed=1000" after "Set Bullet enabled". This will reset the speed.

  • Oh, so the bullet speed increases automatically...

    But amazing,it works, thank you so much!

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