LUA commands for Admin?

Discussion about topics that don't fit elsewhere.
Post Reply
Silvermoon
Posts: 26
Joined: Wed Jan 13, 2010 5:16 pm

LUA commands for Admin?

Post by Silvermoon »

Working on my personal server, I've discovered the help files for administrative commands are woefully inadequate for explaining how to use LUA - to the point the example commands given just cause errors. I have a vague understanding of what the LUA commands themselves do from reading the files, but I cannot figure out how to actually utilize them.
User avatar
the_sandman
Developer
Posts: 150
Joined: Sun Dec 13, 2009 6:52 pm

Re: LUA commands for Admin?

Post by the_sandman »

Try some stuff:

Code: Select all

/ det("Silvermoon")
/ openarea("Silvermoon")

etc.
You can also modify player_type structure directly from lua. Check the .pkg files to see what you can/not access.
C. Blue
Developer
Posts: 392
Joined: Sun Dec 13, 2009 6:28 pm

Re: LUA commands for Admin?

Post by C. Blue »

Oh there was actually some admin docu? ^^ That must be like a decade old probably.
Anyway, as Sandman said, or check out slash.c for slash commands (starting at "do_slash_cmd"), in addition to the commands in the LUA files. First you'll see all the commands that are available to players too, and at some points it'll go "if (admin) ..." and the rest of the commands after that are admin commands.

That said, the most/only important admin commands are probably
/val accountname
which turns an unvalidated account into a valid one. And
/shutdown 0
which shuts the server down.
Silvermoon
Posts: 26
Joined: Wed Jan 13, 2010 5:16 pm

Re: LUA commands for Admin?

Post by Silvermoon »

Thanks, both of you. Got it sorted.
Post Reply