Walking styles
#1

Alright so i have got it working i just need to know how can i make it so when the player has stopped pressing the walk button it will stop the walk style

pawn Code:
if (HOLDING(KEY_WALK))
    {
        if(Player[playerid][UsingGangWalkOne] == 1)
        {
            ApplyAnimation(playerid, "PED", "WALK_gang1", 4.0, 1, 1, 1, 1, 1);
        }

    }
If you need any more code just ask me

Thanks
Reply
#2

Just set the 5th parameter to 1 for looping.

pawn Code:
ApplyAnimation(playerid, "PED", "Player_Sneak", 4.0, 1, 1, 1, 0, 0);
Reply
#3

There is an older include for this:

http://pastebin.com/W11RsR1L
Reply
#4

Quote:
Originally Posted by HellSphinX
View Post
Just set the 5th parameter to 1 for looping.

pawn Code:
ApplyAnimation(playerid, "PED", "Player_Sneak", 4.0, 1, 1, 1, 0, 0);
But when i have to jump or something else to stop the animation how can i make it so when i stop walking it stops the walk style ?
Reply
#5

Please help
Reply
#6

Use OnPlayerKeyStateChange to detect the pressed keys and if it's KEY_JUMP (Find all the availabe keys here) then use ClearAnimations to clear the player's animations.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)