On signal

From Scriptwiki
Jump to: navigation, search

The on signal event triggers if a script has used the /signal command to send a signal to all scripts.

on *:SIGNAL:name:command

The signal name can contain wildcards.

The $signal identifier returns the signal name that caused the signal event to trigger.

The $1- identifier returns the parameters that were specified in the /signal command.

Note: The script that called /signal is triggered first, and then all other scripts are triggered.


on *:SIGNAL:load:hmake database 100 | if ($isfile(database.hsh)) hload database database.hsh

When the "load" signal is triggered, creates a hash table and loads data into the hash table if available.

See Also