TinTin++ Mud Client Manual
Event
space
Syntax: #event {event name} {commands}
space
Events allow the creation of triggers for predetermined client events. Using #event without an argument will list most of the possible events with a brief description. Using #event %* will show all defined events. You can see all events as they trigger by using #info event on. Most events set arguments.
space
CATCH
space
All CATCH events will block normal processing and instead only execute the provided event. Not all events have a CATCH alternative. If you for example use the CATCH RECEIVED INPUT event this event will block normal input processing and for any processing to occure it needs to be handled within the event.
space
Chronological Events
space
All chronological events set the following arguments: %0 - year using 4 digits, %1 - month using 2 zero padded digits, %2 - week number using 2 zero padded digits, %3 - day of the month using 2 zero padded digits, %4 - hour of the day using 2 zero padded digits in military time, %5 - minute of the hour using 2 zero padded digits, %6 - second of the minute using 2 zero padded digits.
space
DATE <MONTH-DAY> [HOUR:MINUTE]
space
Triggers on the given date and time. A date must be provided, a time is optional. If no time is given it'll trigger at midnight.
space
Example: #event {DATE 12-31 23:59} {#showme One minute till New Year!}
space
DAY [DAY]
space
Triggers each day or given day of the month.
space
HOUR [HOUR]
space
Triggers each hour or given hour of the day.
space
MINUTE [MINUTE]
space
Triggers each minute or given minute of the hour.
space
MONTH [MONTH]
space
Triggers at the start of each month or given month at midnight.
space
SECOND [SECOND]
space
Triggers each second or given second of the minute.
space
TIME <HOUR:MINUTE>
space
Triggers at the given time.
space
WEEK [WEEK]
space
Triggers at the start of each week or given week at midnight.
space
YEAR [YEAR]
space
Triggers at the start of each year or given year at midnight.
space
Mouse Events
space
To enable Mouse Tracking mode it must be enabled using #config {MOUSE TRACKING} {ON}.
space
All mouse events set the following arguments: %0 and %1 will contain the column and row that is clicked as measured from the bottom left corner. %2 and %3 contain the column and row as measured from the upper right corner which is always a negative value.
space
In order to see mouse events as they happen enable #info {events} {on}, as this can get rather spammy you can use #gag to remove event notifications you have no interest in seeing.
space
DOUBLE CLICKED
space
Triggers on a double click within 0.5 seconds.
space
LONG CLICKED
space
Triggers when the time between pressing and releasing is longer than 0.5 seconds.
space
MOVED
space
Triggers on moving the mouse while having a button pressed.
space
PRESSED
space
Triggers when a mouse button is pressed.
space
RELEASED
space
Triggers when a mouse button is released.
space
SCROLLED
space
Triggers when the mouse scroll wheel is used.
space
SHORT CLICKED
space
Triggers when the time between pressing and releasing the mouse button is less than 0.5 seconds. This event is not triggered when double or triple clicks occure, but will trigger on the first click of a double click, just like a triple click event will be preceded by a double click event.
space
TRIPLE CLICKED
space
Triggers on a triple click within 0.5 seconds. The click state is reset after receiving a triple click.
space
space
CHAT MESSAGE
space
Triggers when a #chat message is received. %0 contains the raw data, %1 contains the modified data.
space
END OF PATH
space
This event triggers once when reaching the end of a path using #path walk.
space
IAC
space
This event triggers for all telnet negotiations. Use #config {debug telnet} {on} to see the proper name of telnet events as they happen. If you create a telnet event for a telnet negotiation that is normally handled by the mud client, like IAC SB TTYPE, only the event will be executed; the automatic response will be blocked.
space
IAC [DO|DON'T|WILL|DON'T] [OPTION]
space
When triggering DO, DON'T, WILL or WON't options this will stop tintin from automatically handling the option, and you will have to handle it yourself.
space
IAC SB GMCP <MODULE> IAC SE
space
This event triggers on a GMCP (Generic Mud Communication Protocol). The %0 argument contains the module's name, the %1 argument contains the JSON data. The JSON data is converted to tintin's internal variable system so the data can be directly stored using #variable {gmcp[%0]} {%1}. The original JSON data is stored in the %2 argument.
space
IAC SB MSDP [VARIABLE]
space
This event triggers on a MSDP (Mud Server Data Protocol) subnegotiation. The %0 argument contains the variable's name, the %1 argument contains the variable's value. Values are converted to tintin's internal variable system so the data can be directly stored using #variable {msdp[%0]} {%1}
space
IAC [DO|DON'T|WILL|DON'T] MSP
space
This event triggers on a MSP (Mud Sound Protocol) subnegotiation.
space
IAC SB MSSP [VARIABLE]
space
This event triggers on a MSSP (Mud Server Status Protocol) sub negotiation. The %0 argument contains the variable's name, the %1 argument contains the variable's value. If a variable is send as an array a name/value event is generated for each index.
space
IAC [DO|DON'T|WILL|DON'T] MXP
space
This event triggers on a MXP (Mud eXtension Protocol) subnegotiation.
space
IAC SB NEW-ENVIRON <IS|INFO|SEND> [VAR|USR]
space
This event triggers on a NEW-ENVIRON sub negotiation. Depending on the negotiation type you'll have to append SEND, IS, or INFO to the event name, as shown when using #config {debug telnet} {on}. The %0 argument contains the variable's name, the %1 argument contains the variable's value.
space
IAC SB ZMP
space
This event triggers on a ZMP sub negotiation. Depending on the ZMP package you'll have to append the package to the event name, as shown when using #config {debug telnet} {on}. The %0 argument contains the ZMP package data.
space
IAC SB
space
This event triggers on any undefined sub negotiation. Some telnet options will be named, others will be a number, as shown when using #config {debug telnet} {on}. The %0 argument will contain the data inside the sub negotiation.
space
space
MAP ENTER MAP
space
Triggers when entering the map. %0 contains the new vnum.
space
MAP ENTER ROOM [VNUM]
space
This event triggers right after entering a new room in the auto-mapper. The vnum is the room number. The %0 argument contains the vnum of the room, %1 contains the vnum of the departiation room.
space
MAP EXIT MAP
space
Triggers when exiting the map. %0 contains the old vnum.
space
MAP EXIT ROOM [VNUM]
space
This event triggers right before exiting the current room in the auto-mapper. The vnum is the room number. The %0 argument contains the vnum of the room, %1 contains the vnum of the destination room.
space
MAP UPDATED VTMAP
space
Triggers when the VTMAP is updated, which is at most once per 0.1 seconds.
space
space
PORT CONNECTION
space
This event triggers when a new socket connection is made. %0 contains the socket number, %1 the ip address, %2 the port number (set to 0 for incoming connections).
space
PORT DISCONNECTION
space
This event triggers when a socket disconnects. %0 contains the socket number, %1 the ip address, %2 the port number (set to 0 for incoming connections).
space
PORT MESSAGE
space
This even triggers when a socket sends data. %0 contains the socket number, %1 the ip address, %2 the port number (set to 0 for incoming connections), %3 contains the stripped data, %4 contains the raw data.
space
space
PROGRAM START
space
This event triggers at the end of TinTin++'s startup process. %0 contains all the startup parameters and arguments. %1 contains the first argument, %2 the second argument, etc.
space
PROGRAM TERMINATION
space
This event triggers at the end of TinTin++'s termination process inside the startup session.
space
RECEIVED KEYPRESS
space
Triggers on each key press.
space
RECEIVED INPUT
space
This event triggers right after keyboard input has been entered, but before it is executed. The %0 argument contains the raw input.
space
RECEIVED LINE
space
This event triggers when a line is received from the server, right before the execution of any triggers. The %0 argument contains the raw line, the %1 argument contains the plain line, stripped of all color codes.
space
RECEIVED OUTPUT
space
Triggers when new output is received. %0 contains the raw output which can contain multiple lines.
space
SCAN [CSV|TSV] HEADER
space
This event triggers on the first line of a CSV (comma separated values) or TSV (tab separated values) file.
space
SCAN [CSV|TSV] LINE
space
This event triggers on each line of a CSV or TSV file except for the first line.
space
Screen Events
space
While the SCREEN RESIZE event will trigger when the screen is resized, all other events must be raised by using the #screen raise command.
space
SCREEN CHARACTER DIMENSIONS
space
This event is trigged by the #screen raise command. %0 holds the height of a character and %1 holds the width of a character, in pixels.
space
SCREEN DESKTOP DIMENSIONS
space
This event is trigged by the #screen raise command. %0 holds the height of the desktop and %1 holds the width of the desktop, in pixels.
space
SCREEN DIMENSIONS
space
This event is trigged by the #screen raise command. %0 holds the height of the terminal and %1 holds the width of the terminal, in pixels. You can get the screen height and width at all times with the #screen get command.
space
SCREEN MINIMIZED
space
This event is trigged by the #screen raise command. %0 is set to 1 if the screen is minimized, otherwise it's set to 0.
space
SCREEN POSITION
space
This event is trigged by the #screen raise command. %0 holds the height coordinate of the top left corner and %1 holds the width coordinate of the top left corner, in pixels.
space
SCREEN RESIZE
space
This event triggers whenever the screen is resized. %0 contains the number of screen rows, %1 contains the number of screen columns, %2 contains the screen height in pixels, %3 contains the screen width in pixels. You can get these values at all times with the #screen get command.
space
SEND OUTPUT
space
This event triggers right after a command line has been send to the server. The %0 argument contains the raw command line.
space
space
SESSION CREATED
space
Triggers when a session is created. The %0 argument contains the session name, the %1 argument contains the host name, the %2 argument contains the numeric IP address, the %3 argument contains the port number.
space
SESSION ACTIVATED
space
Triggers when a session is activated. The %0 argument contains the session name.
space
SESSION CONNECTED
space
This event triggers right after a session connects to a server. The %0 argument contains the session name, the %1 argument contains the host name, the %2 argument contains the numeric IP address, the %3 argument contains the port number.
space
SESSION DEACTIVATED
space
Triggers when a session is deactivated. The %0 argument contains the session name.
space
SESSION DISCONNECTED
space
This event triggers right after a session is disconnected from a server. The %0 argument contains the session name, the %1 argument contains the host name, the %2 argument contains the numeric IP address, the %3 argument contains the port number.
space
SESSION TIMED OUT
space
This event triggers when a session fails to connect. The %0 argument contains the session name, the %1 argument contains the host name, the %2 argument contains the numeric IP address, the %3 argument contains the port number.
space
UNKNOWN COMMAND
space
Triggers on #jklfdjl and other non-existent commands.
space
space
VARIABLE UPDATE <VARIABLE>
space
This event triggers when a variable is created or updated. The %0 argument contains the variable name, the %1 argument contains the variable value.
space
VT100 [CPR|DA|DECID|DSR|ENQ]
space
These events trigger when terminal identification codes are received. They are poorly documented, rarely used, and can generally be ignored.
space
WINDOW FOCUS [IN|OUT]
space
These events trigger when the window goes in and out of focus.
space
See also: Delay and Ticker.
space