Applyanimation on chat
#1

Can u guys help me? I have no idea how to do this


I am trying to make a chat animation when my people talks.

but doesnt understand aboy applyanimation..

can u help me/make it for me?
Reply
#2

top of script
pawn Код:
forward StopTalk(playerid);
new gPlayerUsingLoopingAnim[MAX_PLAYERS];
somewhere in your script
pawn Код:
StopLoopingAnim(playerid)
{
    gPlayerUsingLoopingAnim[playerid] = 0;
    ApplyAnimation(playerid, "CARRY", "crry_prtial", 4.0, 0, 0, 0, 0, 0);
}

public OnPlayerText(playerid,text[])
{
    ApplyAnimation(playerid, "PED", "IDLE_CHAT", 4.0, 0, 1, 1, 1, strlen(text)*1000, 1);
    SetTimer("StopTalk", strlen(text)*200, false); // CHANGE THE 200 IF YOU WANT THE ANIM TO LAST LONGER
    return 1;
}

public StopTalk(playerid)
{
    ClearAnimations(playerid);
    StopLoopingAnim(playerid);
   
    return 1;
}
PS: weard, I thaught this was already answered yesterday
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)