23.05.2018, 21:22
Use https://sampwiki.blast.hk/wiki/OnPlayerTakeDamage and check if bodypart is different of 9. If it is: SetPlayerHealth with his initial health, like:
PHP код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid, bodypart)
{
new Float:health, Float:armour;
GetPlayerHealth(playerid, health);
GetPlayerArmour(playerid, armour);
if(bodypart != 9) {
SetPlayerHealth(playerid, health);
SetPlayerArmour(playerid, armour);
}
return 1;
}