Debug
From Scriptwiki
Revision as of 13:11, 2 July 2007 by Cail (talk | contribs) (added to category commands, no category before)
Outputs raw server messages, both incoming and outgoing, to a debug.log file, or a custom @window.
/debug [-cinpt] [N] [on|off|@window|filename] [identifier]
Switches
Switch | Meaning |
-c | turns off debugging and closes the associated custom @window |
-i | the specified identifier before a debug line is logged. The return value of the identifier is used as the debug line. |
-n | opens the custom @window minmized. |
-p | turns word wrapping on. |
-t | turns timestamping on. |
Example on using a custom alias:
; we'll make an alias that we will use with /debug -i alias debugoutput { ; the debug line is actually $1, so we'll now tokenize it, so we can use $1 $1- etc. tokenize 32 $1 ; this will just replace those arrows <- and -> (which is $1 after the tokenize) with colored ones return $replace($1, $& <-, $+($chr(3),10,<-,$chr(3)), $& ->, $+($chr(3),04,->,$chr(3)) $& ) $2- } ; now just open the debug window with /debug -i @debug debugoutput