10.04.2017, 10:33
Here's what you could do, I have a similar system in my script.
And then:
Just a thought.
Код:
new Injured[MAX_PLAYERS];
Код:
public OnPlayerUpdate(playerid) { new Float: playersHealth; GetPlayerHealth(playerid, playersHealth); if(playersHealth <= 10) { SendClientMessage(playerid, -1, "You are critically injured. You may /acceptdeath or wait for a medic to revive you."); LoopingAnim(playerid,"SWEET","Sweet_injuredloop", 4.0, 1, 0, 0, 0, 0); Injured[playerid] = 1; } }
Код:
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid, bodypart) { if(Injured[damagedid] == 1) { SetPlayerChatBubble(damagedid, (( THIS PLAYER IS DEAD )), RED, 100.0, 4343344); //or just make a 3d text } }