Page 1 of 1

damage/hit bounce back effects for player?

PostPosted: Sun Mar 29, 2009 8:25 pm
by Darc
how do you make a character when attacked or touched by an enemy move away with out bouncing away too far or out of control?

Re: damage/hit bounce back effects for player?

PostPosted: Sun Mar 29, 2009 10:54 pm
by skydereign
You need to familiarize yourself with variables to make this really efficient, but to get that result you need physical response. Or setting velocity upon collision.

Re: damage/hit bounce back effects for player?

PostPosted: Sat Oct 24, 2015 2:30 am
by Zivouhr
I create a path from Left to Right for a short distance. When the player hits the enemy, in the player collision with right side of enemy/script editor, I'll createPath for the player to respond to when hit on the left side by the enemy, to start the path so the player goes to the right.

Then be sure to add Path Finish in the player, and in that script editor, createPath (none) would be the way to stop the path.

You can add sound, animation also as needed, and may have to reference the draw actor event if necessary, with some variables like "hurtR" or "hurtL" depending.

I don't have the coding here, but that's the general idea. I hope that helps, even if it's 5+ years later. :D