On wallops

From Scriptwiki
Jump to: navigation, search

The on WALLOPS event triggers when you receive a wallops message.

on <level>:WALLOPS:<matchtext>:<commands>


The matchtext can be a wildcard match or even a regular expression. To use regular expressions as matchtext, you need the $-Prefix.

Read access levels to get more info about the <level> field.


This event triggers whenever you receive a:

  • WALLOP - first char is a * (usermode +o required)
  • WALLUSER - first char is a $ (usermode +w required)
  • WALLDESYNCH - no special first char (usermode +g required - desynchs are for server/services to report protocol violations)

Example

The following event will react on every WALLOP, let it be a real WALLOP, a WALLUSER or a WALLDESYNCH.

on *:WALLOP:*: {
 ; if the first word is a *, its a real WALLOP, lets echo it to the status window
 if ($1 == *) { echo -s New WALLOP: $1- }
 ; if its a $, its a WALLUSER
 elseif ($1 == $) { echo -s New WALLUSERS: $1- }
 ; else its a WALLDESYNCH
 else { echo -s New WALLDESYNCH: $1- }
}