if (0) { Script: unet/opercommands URL: http://www.xs4all.nl/~carlo17/irc/ircII/unet/opercommands Description: IRC Operator only commands. Also needed: http://www.xs4all.nl/~carlo17/irc/ircII/unet/stripu http://www.xs4all.nl/~carlo17/irc/ircII/unet/numerics http://www.xs4all.nl/~carlo17/irc/ircII/unet/getname Version: $Id: opercommands 317 2000-05-04 22:53:47Z carlo $ First Ver: 02/05/1998 Author: ircii @t alinoe.com, Run @t IRC } load unet/stripu if (loaded != [unet.stripu]) { echo *** unet/opercommands needs http://www.xs4all.nl/~carlo17/irc/ircII/unet/stripu } load unet/numerics if (loaded != [unet.numerics]) { echo *** unet/opercommands needs http://www.xs4all.nl/~carlo17/irc/ircII/unet/numerics } load unet/getname if (loaded != [unet.getname]) { echo *** unet/opercommands needs http://www.xs4all.nl/~carlo17/irc/ircII/unet/getname } ############################################################################# # # RPING command # # Usage: # # /RPING [] # # Returns the ping time between (local server is default) # and in miliseconds. # alias RPING quote RPING on ^raw_irc "% RPONG *" { echo *R* RPING: $stripu($0) - $stripu($3) : $4 ms } ############################################################################# # # UPING command # # Usage: # # /UPING [] [] [] # # Returns statistics about udp ping between (local server # is default) and . Uses , default is 7007 but in some # cases you can use the unix echo daemon at port 7. is the number # of packets sent, default is 5, maximum is 20 packets. # alias UPING quote UPING on ^raw_irc "%.% NOTICE % :Sending % pings to *" { echo *U* Sending $4-6 $stripu($getname($7)) $8- \($stripu($0)\) } on ^raw_irc "%.% NOTICE % :UPING *" { if ([$4]==[Stats:]) { echo *U* $4- } { echo *U* $stripu($0) -> $stripu($4) : $5- ms } } ############################################################################# # # SETTIME command # # Usage: # # /SETTIME [] # # This corrects the TimeStamp clock on your server (use /TIME to see it). # If you use , the clock of that server is set equal to # the clock of it's uplink, not to the value you give. Use only if you # know what you are doing ! # alias SETTIME quote SETTIME ############################################################################# # # Remote NAMES command # # Usage: # # /NAMES <#channel> # # This fix is needed on my ircII2.8.2, not sure if it's needed elsewhere. # It's only needed to look for possible ghosts. # This alias only works when you don't use a comma seperated channel list. # alias NAMES { if ([$1] != []) { quote NAMES $0 $1 ^on ^353 * { echo $1- \(from $0\) } ^eval on ^366 "% $0 *" { echo *** $1: $2- \(from $0\) on ^353 -* eval on ^366 -"% $0 *" } ^on ^402 "$1 *" { echo *** Received 402 } assign lastnames $1 ^ON -481 * { ON ^353 -* ON ^402 -"$lastnames *" assign -lastnames ON ^481 * } } { //NAMES $0 } } ############################################################################## # # WHOX command # # Usage: # # /WHOX "masklist" ["flaglist"[,"quertype"]] ["masklist"] # # See doc/readme.who for more details. # # Default /WHOX format: user IP host server nick flags assign whoxformat uihsnf alias WHOX { IF ([$0] == []) { echo *** /WHOX $C : quote WHO $C x%${whoxformat}t,101 } { IF ([$1] == []) { echo *** /WHOX $0 : quote WHO $0 x%${whoxformat}t,101 } { echo *** /WHOX $0 $1 : quote WHO $0 $1t,0 } } } ############################################################################# # # '/HIDE' will suppress client connect/disconnect notices when you are opered # '/SHOW' will start showing them again # alias show { quote MODE $N +s +16384 echo *** You can now see clients connecting/exiting } alias hide { quote MODE $N -s +16384 echo *** You will no longer see clients connecting/exiting } on ^server_notice "% % NOTICE -- CLIENT*" echo *^BN^B* $2- on ^server_notice "% % NOTICE -- Invalid username:*" echo *^BN^B* $2- @version=101 @loaded=[unet.opercommands]