advancedadmin.lua editions


(NovaPrime) #1

I am trying to add a few commands to Micha’s advancedadmin.lua to make shortcuts for etpub server

!listplayers – !li
!nextmap – !ne

and a command change…
/follow – !spec (and want it to stay following even when they respawn)

I tried doing the !li shortcut below but think this portion of code is wrong maybe

		elseif (string.find(et.trap_Argv(0), "^" .. li_cmd .. "") or string.find(et.trap_Argv(1), "^" .. li_cmd .. "")) then
			et.trap_SendConsoleCommand( et.EXEC_APPEND, "listplayers" )

I have some source code for the spec command if needed


(Micha) #2

I could not get listplayers to work, same goes for help. I think it is not possible to trigger this command.
I made a userinfo lua which gives some more infos and has a shortend listplayers in it: http://mnwa.bplaced.net/ftpfiles/Lua/userinfo.lua
Nextmap could be done like the others I have in the advancedadmin.lua.

Spec lua: http://mygamingtalk.com/forums/files/file/31-spec-command/


(NovaPrime) #3

This worked, thank you!