03.09.2017, 14:05
Why not use OnPlayerTakeDamage?
Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid, bodypart) { new Float:health, Float:armor; GetPlayerHealth(playerid, health); GetPlayerArmour(playerid, armor); if(playerid != INVALID_PLAYER_ID) { if(PlayerInfo[playerid][pFreezeTime] != 0) { SetPlayerHealth(playerid, health); SetPlayerArmor(playerid, armor); return SendClientMessage(issuerid, -1, "This player is frozen, you can't shoot him."); } } return 1; }