Jump to content

Is knockback possible?


Soopakoopa

Recommended Posts

It should easily be possible, even without changing the stategraph. The only question is: do the character physics even allow that?

 

For the case you don't know what I mean, try spawning something up in the air and watch is slowly descent. Or try to launch the player in the air.

Link to comment
Share on other sites

It should easily be possible, even without changing the stategraph. The only question is: do the character physics even allow that?

 

For the case you don't know what I mean, try spawning something up in the air and watch is slowly descent. Or try to launch the player in the air.

 

   No, I'm not talking about launching entities vertically; I simply mean a weapon which

pushes a mob back away from the player for a certain predetermined horizontal distance.

Is that possible, and if so, how would one go about doing it?

Link to comment
Share on other sites

The game's physics engine should be able to handle a velocity vector, so you could make something arc rather than fall straight down. I believe that's the method behind items bouncing when they hit the ground. Check the boomerang and other projectiles to see how they're handled fro more info.

 

The reason Mobbstar suggested using the physics engine is that it could otherwise require fiddling with stategraph files to include a knockback event. And if you want the knockback weapon to work on more than one creature type, that's a lot of stategraph files.

 

Another alternative would be to teleport the creature a very small distance away from the player every fraction of a second. It might look a little jittery though.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...