SA-MP Forums Archive
Animation - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Animation (/showthread.php?tid=185792)



Animation - Bessensap - 26.10.2010

I'm looking for the Animation that ur like in pain because u just got hit by a fire_extinguisher or spraycan; ur covering ur face with ur hands and ur bent down, i searched the forum and the animations page on the wiki but i just can't find it, does anyone know the name and the library of this anim?


Re: Animation - The_Moddler - 26.10.2010

Use GetPlayerAnimationIndex when playing the anim..


Re: Animation - boelie - 26.10.2010

this one;

ApplyAnimation(playerid,"ped","gas_cwr",4.1,0,0,0, 0,0);


Re: Animation - Slice - 26.10.2010

You can find it yourself. This should work (haven't tested it):

pawn Код:
#include <a_samp>

new
    g_iPreviousAnimation[ MAX_PLAYERS ]
;

public OnPlayerUpdate( playerid )
{
    static
        s_iAnimation
    ;
   
    s_iAnimation = GetPlayerAnimationIndex( playerid );
   
    if ( s_iAnimation != g_iPreviousAnimation[ playerid ] )
    {
        new
            s_szMessage[ 80 ],
            s_szLibrary[ 32 ],
            s_szAnimation[ 32 ]
        ;
       
        g_iPreviousAnimation[ playerid ] = s_iAnimation;
       
        GetAnimationName( s_iAnimation, s_szLibrary, sizeof( s_szLibrary ), s_szAnimation, sizeof( s_szAnimation ) );
       
        format( s_szMessage, sizeof( s_szMessage ), "Animation: %s_%s (%d)", s_szLibrary, s_szAnimation, s_iAnimation );
       
        SendClientMessage( playerid, -1, s_szMessage );
    }
   
    return 1;
}



Re: Animation - Bessensap - 26.10.2010

@The_Moddler, i'd have to be knowing the name before i could be able to play it, no?

@boelie THANKS