-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy pathStaff Globals - SGLOB.txt
executable file
·13 lines (8 loc) · 2.16 KB
/
Staff Globals - SGLOB.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
@@ DEPENDENCIES - CORE
th u(NEWCOBJ,Staff Globals <SGLOB>,sglob,,,,WIZARD SAFE !NO_COMMAND,INHERIT SIDEFX SAFE)
@lock/use [u(cobj,sglob)]=ISADMIN2/1
&CMD`+DEBUG [u(cobj,sglob)]=$+debug *:@check u(setr,find,u(firstof,locate(%#,%0,u(choosegame,,*)),u(cobj,%0)))=@attach %!/INC`MSG=ERROR: Sorry. %0 not found.;@set %q<find>=u(choosegame,DEBUG VERBOSE PUPPET,TRACE VERBOSE PUPPET);@debugforwardlist %q<find>=setdiff(setunion(%#,get(%q<find>/DEBUGFORWARDLIST)),owner(%q<find>));@power %q<find>=pemit_all;@attach %!/INC`MSG=DEBUG for [name(%q<find>)] enabled!
&CMD`+UNDEBUG [u(cobj,sglob)]=$+undebug *:@check u(setr,find,u(firstof,locate(%#,%0,u(choosegame,,*)),u(cobj,%0)))=@attach %!/INC`MSG=ERROR: Sorry. %0 not found.;@set %q<find>=u(choosegame,!DEBUG !VERBOSE !PUPPET,!TRACE !VERBOSE !PUPPET);@debugforwardlist %q<find>=setdiff(get(%q<find>/DEBUGFORWARDLIST),%#);@power %q<find>=!pemit_all;@attach %!/INC`MSG=DEBUG for [name(%q<find>)] disabled!
&CMD`+BITS [u(cobj,sglob)]=$+bits:@pemit %#=u(header,Priveleged Players);@pemit %#=align(25 3 3 3 10,Name,WIZ,ROY,JDG,Owns);@dolist/inline u(sortname,lsearch(all,type,player,elock,FLAG^WIZARD|FLAG^ROYALTY|FLAG^JUDGE))={@pemit %#=align(25 -3 -3 -3 10,name(%i0),if(hasflag(%i0,WIZARD),ansi(hr,Y),N),if(hasflag(%i0,ROYALTY),ansi(hb,Y),N),if(hasflag(%i0,JUDGE),ansi(hy,Y),N),bound(sub(nsearch(%i0),1),0))};@pemit %#=u(header,Priveleged Objects);@pemit %#=align(32 3 3 3 15 15,Name,WIZ,ROY,JDG,Owner,Location);@dolist/inline sortkey(#lambda/owner(\%0),lsearch(all,type,thing,elock,FLAG^WIZARD|FLAG^ROYALTY|FLAG^JUDGE),namei)={@pemit %#=align(32 -3 -3 -3 15 15,name(%i0),if(hasflag(%i0,WIZARD),ansi(hr,Y),N),if(hasflag(%i0,ROYALTY),ansi(hb,Y),N),if(hasflag(%i0,JUDGE),ansi(hy,Y),N),name(owner(%i0)),name(loc(%i0)))};@pemit %#=u(header)
&CMD`+DARK [u(cobj,sglob)]=$^(?s)(?\:\+)?dark(?\:/(\S+)?)?$:@attach %!/INC`PARTIAL=%1,ON|OFF,|,switch,switch;@select/inline haspower(%#,can_dark)=0,{@power %#=can_dark};@select/inline %q<switch>=OFF,{@set %#=!dark;@dolist/inline ports(%#)=@hide/off %i0;@pemit %#=Shown.},ON,{@set %#=dark;@dolist/inline ports(%#)=@hide/on %i0;@pemit %#=Hidden.},{@attach %!/CMD`+DARK=,if(hasflag(%#,DARK),Off,On)}
@set [u(cobj,sglob)]/CMD`+DARK=regexp