Code: Select all
bind nick - * xmas
proc xmas {n u h c nn} {
if ![botisop $c] return
set xold [string match -nocase *xmas* $n]
set xnew [string match -nocase *xmas* $nn]
if {!$xold && $xnew} {
pushmode $c +v $n; flushmode $c
} elseif {$xold && !$xnew} {
pushmode $c -v $n; flushmode $c
}
}
Code: Select all
bind nick - * xmas
proc xmas {n u h c nn} {
if ![botisop $c] return
set xold [string match -nocase *xmas* $n]
set xnew [string match -nocase *xmas* $nn]
if {!$xold && $xnew} {
pushmode $c +v $nn
} elseif {$xold && !$xnew} {
pushmode $c -v $nn
}
}
Code: Select all
bind nick - * xmas
bind join - * xmas
proc xmas {n u h c {nn ""}} {
if ![botisop $c] return
set xold [string match -nocase *\[yourtag\]* $n]
set xnew [string match -nocase *\[yourtag\]* $nn]
if {$nn == ""} {
if {$xold} {
pushmode $c +v $n
}
} else {
if {!$xold && $xnew} {
pushmode $c +v $nn
} elseif {$xold && !$xnew} {
pushmode $c -v $nn
}
}
}
Code: Select all
set tvchans "#channel #channel2"
bind nick - * xmas
bind join - * xmas
proc xmas {n u h c {nn ""}} {
if {(![botisop $c]) || ([lsearch -exact $::tvchans $c] == -1)} { return }
set xold [string match -nocase "\[yourtag\]*" $n]
set xnew [string match -nocase "\[yourtag\]*" $nn]
if {$nn == ""} {
if {$xold} {
pushmode $c +v $n
}
} else {
if {!$xold && $xnew} {
pushmode $c +v $nn
} elseif {$xold && !$xnew} {
pushmode $c -v $nn
}
}
}
Code: Select all
set xold "[string match -nocase "\[yourtag\]*" $n]"
...
if {$xold} {
pushmode $c +v $n
}
...