Page 1 of 1

sliding?

PostPosted: Sat Nov 22, 2008 12:27 am
by smallville
how do i make sliding? so that on the key up event the player will slide a bit according to the velocity of
the running, dashing, attacking or jumping?

Re: sliding?

PostPosted: Sat Nov 22, 2008 7:22 am
by skydereign
One way of doing this, if I understand what you are asking, is to; On keydown event, set the xvelocity to whatever you want, and in the draw actor script, have it decelerate: if (xvelocity>=20){xvelocity-=5;}....else if (xvelocity>=1){xvelocity-=.1;} Setting up all the intermediates that you need.

Re: sliding?

PostPosted: Thu Jan 15, 2009 8:07 pm
by Kalladdolf
Make sure you have set the right physical response values, otherwise your actor will just stick to the ground.
(All four values one; Mass: specify, assuming that you use the PhysicalResponse action at all, that is.)