NPC Animation
#1

Ay guys, well can anyone show me how to apply animation on a NPC that will be constant? (Constant loop)

This is my current code. But the animation wont work at all.
Код:
if(IsPlayerNPC(playerid))
	{
        new npcname[MAX_PLAYER_NAME];
        GetPlayerName(playerid, npcname, sizeof(npcname));
        if(!strcmp(npcname, "Drug_D_Main", true))
		{
            SetPlayerSkin(playerid, 113);
            ApplyAnimation(playerid,"PAULNMAC", "wank_loop", 1.800001, 1, 0, 0, 1, 600);
        }
        return 1;
    }
Also I tried with:

Main GM Script:
Код:
CMD:crossarms(playerid, params[])
{
    ApplyAnimation(playerid,"PAULNMAC", "wank_loop", 1.800001, 1, 0, 0, 1, 600);
    return 1;
}
NPC script
Код:
  public OnPlayerStreamIn(playerid)
	{
		SendCommand("/crossarms");
		return 1;
	}
Reply
#2

So, it doesn't work even if you do it?
Make sure the animlib and animation name are correctly, and apply the animation twice.
pawn Код:
CMD:crossarms(playerid, params[])
{
    ApplyAnimation(playerid,"PAULNMAC", "wank_loop", 1.800001, 1, 0, 0, 1, 600);
    ApplyAnimation(playerid,"PAULNMAC", "wank_loop", 1.800001, 1, 0, 0, 1, 600);//apply it twice!
    return 1;
}
Reply
#3

The issue is that it works for the player itself, but it wont work on the NPC.


When you type /crossarms in game it will work perfectly but the NPC wont be playing any animations at all.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)