SA-MP Forums Archive
Admin Script - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Admin Script (/showthread.php?tid=243679)



Admin Script - IvancheBG - 24.03.2011

How to make an admin script with admin command and e.t.c?


Re: Admin Script - BASITJALIL - 24.03.2011

https://sampwiki.blast.hk/wiki/Creating_...n_FilterScript
Here you can find how to make a Adm Script


Re: Admin Script - PinkFloydLover - 24.03.2011

I'll explain to you the very basics, this is without saving it to a file.

On top of your script add:
pawn Код:
new AdminLevel[MAX_PLAYERS];
This is the variable we are going to store your admin level in.

Then you need to make a command to set the admin level.

pawn Код:
if (strcmp("/password", cmdtext, true) == 0)
        {
            AdminLevel[playerid] = 5;
            return 1;
        }
This command makes the person that types, "/password", a level 5 admin.
Change "password", to a password of your choice.

And that's it. I wont go into creating commands like "/kick", and "/ban", you will need to search for a proper tutorial, there are hundreds in the tutorial section.