Enemy damage and bounces

  • Any way that when I jump on a character, she kills the enemy, but when she move into him she takes damage the character bounce? ( I know it's kinda complicate) :)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • #1

    First add event: Player - On Collision with Enemy, then add a sub-event: Player - Platform is falling, add another condition: Player - Compare Y (put comparison: < less than, Y co-ordinate: Enemy.Y) -> (add action) Enemy - Destroy, (another action) Player - Set Platform vector Y to -500(this makes your player bounce when you jump over and kill your enemy, mario style).

    #2

    Right click on the left side of player - platform is falling and compare Y, Add -> Add else.

    System - Else -> (add action) Player - subtract 1 from health, (another action) Player - Set animation to "your damaged animation".

    Also go to your player animations - your damaged animation properties and set Loop -> No, so you animation doesnt repeat over and over after you collide with enemy once. Instead it plays once per collision.

    This should look like this...

    I hope all this isnt to much complicated.

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