on @*:text:!abductme:#:{
set %question $calc($hfind(AS,$+(*,$address),0,w) + 1)
if %question <= $lines(questions.txt) {
.enable #input
set %chan $chan
question $nick $address %question
}
else .mode # +v $nick
}
#input off
alias question {
set %address $2
.msg $1 $read(questions.txt,$3)
set %entry $gettok($read(questions.txt,$3),-1,32)
}
on *:text:*:?:{
if %address = $address {
.hadd -m AS $+(%entry,.,$address) $1-
inc %question
if (%question <= $lines(questions.txt)) {
question $nick $address %question
}
else {
.disable #input
.close -m $nick
.mode %chan +v $nick
}
}
}
#input end