SA-MP Forums Archive
How create gui command? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: How create gui command? (/showthread.php?tid=609898)



How create gui command? - cielkute - 17.06.2016

How create gui command?

Код:
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;
}
how create using dialog?


Insert player name and him heal.

Somebody help


Re: How create gui command? - K0P - 17.06.2016

https://sampwiki.blast.hk/wiki/ShowPlayerDialog


Re: How create gui command? - cielkute - 17.06.2016

Bro insert this commands dialog, me need totorial.