28.11.2014, 14:38
Hello.
I'm having a little issue, I made anti spawn kill and i have added objects to the player like shield and a mask.
After spawn protection is over only the shield is being removed.
I'm having a little issue, I made anti spawn kill and i have added objects to the player like shield and a mask.
After spawn protection is over only the shield is being removed.
PHP код:
forward SP(playerid);
public SP(playerid)
{
SendClientMessage(playerid, -1, "{00CC00}You are no longer spawn protected.");
SetPlayerHealth(playerid, 100);
for(new i=0; i<MAX_PLAYER_ATTACHED_OBJECTS; i++)
{
if(IsPlayerAttachedObjectSlotUsed(playerid, playerid)) RemovePlayerAttachedObject(playerid, playerid);
}
return 1;
}