Function to check a certain animation
#4

I think the easiest way would be to set a player variable for a player when he uses /handsup, and then check if the variable is true when you use /cuff.

If you're really into using the GetPlayerAnimationIndex
Approach like this:

Код:
new lib[32];
new index[32];
if(GetPlayerAnimationIndex(playerid)) GetAnimationName(GetPlayerAnimationIndex(playerid),lib,32,index,32);
if(strcmp(lib,"PED") == 0 && strcmp(index,"HANDSUP") == 0)
{
 //player will be cuffed
}
I did not test this
Reply


Messages In This Thread
Function to check a certain animation - by MarcGonzales - 13.02.2015, 13:40
Re: Function to check a certain animation - by bartekdvd - 13.02.2015, 13:45
Re: Function to check a certain animation - by MarcGonzales - 13.02.2015, 13:50
Re: Function to check a certain animation - by shadowdog - 13.02.2015, 13:58
Re: Function to check a certain animation - by bartekdvd - 13.02.2015, 14:10

Forum Jump:


Users browsing this thread: 1 Guest(s)