Animation not working
#1

Animations doesn't work

Код:
forward DelayedAnthrax(playerid);
public DelayedAnthrax(playerid)
{
	SetWeather(68);
    SetWorldTime(7);
    AnthraxActivated = 1;
	AnthraxIssuer = playerid;
    SendClientMessageToAll(COLOR_MAROON,"[ANTHRAX] Anthrax bomb has been launched all over San Andreas.");
    if(PInfo[playerid][NoDamage] == 1) return 1;
   	for(new i = 0; i < MAX_PLAYERS; i ++)
   	{
    	if(PInfo[i][God] == 1 || PInfo[i][pAdminDuty] == 1 || PInfo[i][ASP] == 1 || PInfo[i][NoDamage] == 1)
		return 1;
        GameTextForPlayer(i, "~r~ANTRHAXED!",2000,3);
        SetPlayerDrunkLevel(i,2000);
        ApplyAnimation(i,"GRAFFITI","graffiti_Chkout",4.1,1,1,1,1,1,5);
        ApplyAnimation(i,"GRAFFITI","graffiti_Chkout",4.1,1,1,1,1,1,5);
    	GetPlayerHealth(i,health);
    	SetPlayerHealth(i,health -90.0);
    	SendClientMessage(i,COLOR_RED,"You got affected by the anthrax bomb,you will feel dizzy for few seconds.");
	}
	return 1;
}
Reply
#2

Why have you set forcesync to 5?
I believe forcesync can only be 0, 1 and 2.
Reply
#3

https://sampwiki.blast.hk/wiki/ApplyAnimation
Reply
#4

ah my bad,i thought its time parameter

EDIT: still not working

ApplyAnimation(i,"ped","gas_cwr",4.1,0,1,1,0,10,1) ;
Reply
#5

Use this code to preload an animation.

pawn Код:
stock PreloadAnims(playerid) {
        ApplyAnimation(playerid,"GRAFFITI","graffiti_Chkout",4.1,1,1,1,1,1,5);
        ApplyAnimation(playerid,"GRAFFITI","graffiti_Chkout",4.1,1,1,1,1,1,5);
    return 1;
}

//under OnPlayerSpawn//
PreloadAnims(playerid);
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)