evidently I cant see my own } errors
try this
allchans {
var %i = 1
var %c = $chan(0)
while (%i <= %c) {
if ($me !isop $chan(%i)) {
os mode $chan(%i) +o $me
.timerdelay 1 3 mode $chan(%i) $1-
}
else {
mode $chan(%i) $1-
}
inc %i
}
}
to change channel mode:
/allchans (+/-)mode
fex: /allchans +nt-R
to op a nick in all channels you are in (doesnt check for $comchannel)
/allchans (+/-) mode Nick
fex: /allchans +o superman