14.06.2012, 15:04
I wish to use The taser Object that was made in 0.3C with a Knife Anymation , But ive no idea how to put the knife anymation of i put it in there the animation only works when i do /tazer not when i click my lines
Help pls?
PHP Code:
if(strcmp(cmd, "/tazer", true) ==0 || strcmp(cmd, "/ta", true) ==0)
{
if(IsACop(playerid) && PlayerInfo[playerid][pDuty] == 1)
{
if(playerIsHoldingTazer[playerid] == 0)
{
playerIsHoldingTazer[playerid] = 1;
format(string, sizeof(string), "%s gets out his tazer.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE);
SetPlayerAttachedObject(playerid, 0, 18642, 6, 0.06, 0.01, 0.08, 180.0, 0.0, 0.0);
return 1;
}
else if(playerIsHoldingTazer[playerid] == 1)
{
playerIsHoldingTazer[playerid] = 0;
format(string, sizeof(string), "%s puts his tazer back.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE);
RemovePlayerAttachedObject(playerid, 0);
return 1;
}
}
else if(IsACop(playerid) && PlayerInfo[playerid][pDuty] == 0)
{
SendClientMessage(playerid,COLOR_GREY, "You are not on duty.");
return 1;
}
else
{
SendClientMessage(playerid, COLOR_GREY, "You are not a cop.");
return 1;
}
}