01.12.2011, 16:35
pawn Код:
if(strcmp(cmd, "/aceitar", true) == 0)
{
new plid;
new aname[MAX_PLAYER_NAME];
GetPlayerName(playerid, aname, MAX_PLAYER_NAME);
if(IsPlayerConnected(playerid))
{
if(convitevida[plid] == 1){
SendClientMessage(plid,Amarelo, "Vocк aceitou o curativo!");
format(string, sizeof(string), "O Player %s(ID: %d) aceitou o curativo.", aname, plid);
SendClientMessage(playerid, Amarelo, string);
SetPlayerHealth(playerid, 100);
GivePlayerMoney(plid, 200);
GivePlayerMoney(playerid, -100);
convitevida[plid] = 0;
}
}
return 1;
}