SA-MP Forums Archive
How to make - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Server (https://sampforum.blast.hk/forumdisplay.php?fid=6)
+--- Forum: Server Support (https://sampforum.blast.hk/forumdisplay.php?fid=19)
+--- Thread: How to make (/showthread.php?tid=601047)



How to make - DarkScimitar - 16.02.2016

Hi I wanted to ask how to make /makeadmin only for rcon so it can only be used if you are logged into the rcon


Re: How to make - Banditul18 - 16.02.2016

Код:
CMD:makeadmin (playerid,params [])
{
    If(IsPlayerAdmin (playerid))
    {
         //your code
    }
   else return 0;
   return  1;
}



Re: How to make - FreAkeD - 16.02.2016

You'll need zcmd for this if you don't have it already that is.

Код:
CMD:setadmin(playerid, params[])
{
    if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, 0xFF0000FF, "You can't use this command."); // If the player isn't an admin

    // If the player is admin. All code for that goes here.
    return 1;
}
Also, post in the correct section next time. http://forum.sa-mp.com/forumdisplay.php?f=12