Quote:
Originally Posted by Jamester
You would need to put that at the start.
PHP код:
if(strcmp(params, "death", true) == 0) {
if(GetPVarInt(playerid, "Injured") == 1) {
for(new i; i < MAX_PLAYERS; i++) { // GetPlayerPool() or foreach is highly recommended!
if(playervar[i][emsvar/faction]) {
return SendClientMessage(playerid, COLOR_GREY, "There is a EMS online!");
break;
}
}
SendClientMessageEx(playerid, COLOR_WHITE, "You gave up hope and fell unconscious, you were immediately sent to the hospital.");
KillEMSQueue(playerid);
ResetPlayerWeaponsEx(playerid);
SpawnPlayer(playerid);
}
else { SendClientMessageEx(playerid, COLOR_GREY, " You are not injured, you can't do this right now !"); }
|
if(playervar[i][emsvar/faction]) { - I need to change it in if(IsAMedic(playerid))?