#1

OK, So as part of my GM I have a /stun script. However, when you get /stun'ned you do nothing, just stand there, lol.
This is the code:


pawn Код:
if(!IsPlayerInAnyVehicle(NearestPlayer) )
                {
                    TogglePlayerControllable(NearestPlayer, false);
                    Player[NearestPlayer][Tazed] = 1;
                    format( string, sizeof( string ), "* %s has stunned %s, with their taser.", UnderscoreToSpaceName( playerid ), UnderscoreToSpaceName(NearestPlayer) );
                    NearByMessage( playerid, NICESKY, string);
                    SendClientMessage(NearestPlayer, WHITE, "You have been tased. The effect will last for 12 seconds." );
                    SetTimerEx( "UntazePlayer", 12000, false, "d", NearestPlayer);
                }
                else
So I added:

pawn Код:
ApplyAnimationEx( playerid, "PED", "FLOOR_hit_f", 3.1, 0, 1, 1, 1, 1);// Taze Animation
And then the person who does the stunning falls over. LOL.

So I changed 'playerid' to 'NearestPlayer' thinking at that is the variable which defines the bitch that gets tazed. But when doing this, is just makes them stand there, just link before.


Any advice? I want the person who gets tazed to
pawn Код:
ApplyAnimationEx( ???, "PED", "FLOOR_hit_f", 3.1, 0, 1, 1, 1, 1)
Cheers.
Reply
#2

ApplyAnimationEx( NearestPlayer, "PED", "FLOOR_hit_f", 3.1, 0, 1, 1, 1, 1);
Reply
#3

If you read my OP it says I tried that...
Reply
#4

Where did you add the anim?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)