17.06.2016, 17:37
How create gui command?
how create using dialog?
Insert player name and him heal.
Somebody help
Код:
CMD:heal(playerid, params[]) { new pID; if(sscanf(params, "u", pID)) return SendClientMessage(playerid, RED, "Usage: /heal playerid"); if(gClass[playerid] == Medicklase || gClass[playerid] == Supporter) { if(HealthCD[playerid] == 1) return SendClientMessage(playerid, COLOR_RED, "Please wait another 1 minute before using /heal again"); if(IsPlayerInRangeOfPlayer(playerid, pID, 5)) { if(playerid != pID) { SetPlayerHealth(pID, 100); GivePlayerMoney(playerid, 150); GivePlayerMoney(pID, -150); HealthCD[playerid] = 1; SetTimerEx("EndHealthAbuse", 60000, false, "i", playerid); SendClientMessage(pID, RED, "You have been healed."); SendClientMessage(playerid, RED, "You have healed the player."); } else { SendClientMessage(playerid, RED, "You can't heal yourself."); } } else { SendClientMessage(playerid, RED, "You aren't close enough to the player."); } } else SendClientMessage(playerid, RED, "(ERROR): You should be in medic class, to use this command"); return 1; }
Insert player name and him heal.
Somebody help