SA-MP Forums Archive
Animation when talk ? - 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)
+--- Thread: Animation when talk ? (/showthread.php?tid=603015)



Animation when talk ? - VenusDarkX - 17.03.2016

Hello guys, I just looking for some code will apply an animation when player chat, sorry about bad English


Re: Animation when talk ? - SickAttack - 17.03.2016

https://sampwiki.blast.hk/wiki/ApplyAnimation
https://sampwiki.blast.hk/wiki/Animations


Re: Animation when talk ? - VenusDarkX - 17.03.2016

Quote:
Originally Posted by SickAttack
Посмотреть сообщение
Okay I have this code but player still can move their hands normal after apply animations.
Quote:

public OnPlayerText(playerid, text[])
{
if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
{
new Length = strlen(text);
new time = Length*200;
ApplyAnimation(playerid,"PED","IDLE_CHAT",4.1,0,1, 1,1,time);
ClearAnimations(playerid);
return 1;
}




Re: Animation when talk ? - SickAttack - 17.03.2016

pawn Код:
public OnPlayerText(playerid, text[])
{
    if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
    {
        new length = strlen(text), time = (length * 200);
        ApplyAnimation(playerid, "PED", "IDLE_CHAT", 4.1, 0, 1, 1, 1, time, 1);
    }
    return 1;
}