How do I stop platform behavior remembering it's momentum?

0 favourites
  • 4 posts
From the Asset Store
It's here!
$4.95 USD
Creepy and nasty horror track. It's terrifying from the beginning till the end. Goosebumps guaranteed
  • I'm sure that this must be a very simple thing to do, but I appear to be having a little issue with using the platform behavior with enemy movement.

    Basically the enemies have the platform behavior to control them. Upon the player attacking an enemy on the ground it's not a problem, but if the enemy is attacked in the air, whilst they're jumping over the player, I want them to stop their current momentum and fall down to the ground. The problem is, I can't seem to get this to work. They just keep going along their current trajectory. Disabling the behavior just stops them dead in their tracks and ignores gravity. Disabling and re-enabling the behavior just resumes the trajectory too.

    Is this a case of needing another behavior attached to the enemies, that it switches to upon them being attacked?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • disable - set gravity and then resume as needed

  • Sounds like you just need to set the enemy's VectorX to 0 when it's hit.

  • Sounds like you just need to set the enemy's VectorX to 0 when it's hit.

    This sorted the issue out perfectly! Many thanks Kyuzo

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