|
|
|
The system maintained several predefined variables for you to use:
%action the action executed from the last trigger
%caption returns menu caption for speedmenus created by list format
%char the character name of the current session
%class name of current default class
%cr a carrige return character
%crlf a carrige return and a linefeed character, together they are called newline
%lf a linefeed character
%cmud the global CMUDApplication COM object
%context retrieve the name of the class executing the script (added in v2.12)
%ctime the number of seconds you have been connected to the MUD
%curwin the name of the active MUD window with the keyboard focus
%curwinid the unique id of the active MUD window with the keyboard focus
%def current list of special characters
%host the host name of the current MUD
%i same as %repeatnum
%ioresult the result of the last I/O command, 0 if it was successful
%ip the current IP address of your computer
%key the current key value of a record variable within the #LOOPDB command
%lastcom the last command executed
%lastcom2 the command before the last command executed
%lastcom3 the command before %lastcom2
%lastinput the last line of commands executed
%lastin2 the line before the last line of commands executed
%line the last line received from the MUD
%line2 the line before the last line received
%line3 the line before the line before the last line received
%linecol color attribute of the first character in the current line
%module retrieve the name of the current module executing the script (added in v2.12)
%mud retrieve an MXP entity (variable). For example %mud.hp would retrieve the entity called "hp"
%mxp retrieve arguments from MXP tag within an MXP Trigger. For example, <COLOR red> results in %mxp.fore="red"
%names returns a string list of all open window names
%null an empty variable value
%param1..%param99 the parameters from the last trigger match
%pass the password of the current session. Only works within a script. Returns a blank value if used from the command line.
%port the current port connected to
%rec the current database record
%repeatnum the current index during repeating commands, or loop command
%secs a millisecond precision timer
%selected returns the text currently selected in the output or command buffer
%selline returns line that was right-clicked on
%selpos returns column number that was right-clicked on
%selword returns word that was right-clicked on
%session the current CMUDSession COM object for the current window
%sessionnum returns the unique session number
%tick returns the number of seconds on the tick timer
%title the title of the current MUD
%trigger the line that caused the last trigger
%val the current value of a record variable key within the #LOOPDB command
%version current version of CMUD. For example, v5.30 is returned as 530
%window the name of the current window (the window that caused the trigger)
%windowid the id of the current window (the window that caused the trigger)
%zmap returns whether the zMapper program is active as a plugin
%1..%99 the patterns enclosed in () saved by the trigger or parameters passed to an alias
%t1..%t99 the patterns enclosed in () from any trigger state saved by the trigger
%x1..%x99 the XStart and XEnd positions of patterns matched in the trigger |
|