description: netsplit detector.
action: msg all channel that u were on.. announcing the split server.
this simple snippet work based on user`s quit messages. when it see quit message with the network name on 1st and 2nd text of the quit message this snippets will triggered. the user must be on the same channel that you were on so the snippets can "see" the quit message.
i add some colour text on the announcer msg. but it will auto strip into regular text depends on the channel mode.. since there is mode +c ( no colour) on some network.
on *:quit:{
if ($network isin $1) && ($network isin $2) {
var %c $chan(0)
while (%c) {
var %m 14,1 °15 S14erver 15S14plit 15D14etected 15B14etween: $1 15A14nd $2 14°
msg $chan(%c) $iif(c isincs $chan(%c).mode, $strip(%m) , %m )
dec %c
}
}
}
@k0ji: usually i use a separate group for this snippets.. so it only announcing once in a period of times.. here the example
#split on
on *:quit:{
if ($network isin $1) && ($network isin $2) {
var %c $chan(0)
while (%c) {
var %m 14,1 °15 S14erver 15S14plit 15D14etected 15B14etween: $1 15A14nd $2 14°
msg $chan(%c) $iif(c isincs $chan(%c).mode, $strip(%m) , %m )
dec %c
}
.disable #split | .timersplit 1 90 .enable #split
}
}
#split end
as we see above i put a timer 90 sec interval. so this snippets only announcing split to all chans in 90 sec interval