24.07.2012, 11:51
https://sampwiki.blast.hk/wiki/GetPlayerTeam
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/heal", cmdtext, true, 10) == 0)
{
if(GetPlayerTeam(playerid) == TEAM_ME)
{
new targetid;
SetPlayerHealth(targetid,100);
}
else
{
SendClientMessage(playerid,0xE00404,"You are not a medic");
}
return 1;
}
return 0;
}