i did a little script , when an owner type .enfer (nick ) it suppose to give the user the flag +E then send the user in chan 666 on the partyline and lock him in until he say a certain sentence after that the +E is remove and the user send back to the partyline .
heres the problem the script doesnt set the +E flag so the user can escape anytime
# BINDS
# -----
bind filt E * filt:enfer
bind chjn - * chjn:enfer
bind chon E * chon:enfer
bind dcc m enfer dcc:enfer
# CODE
# ----
proc filt:enfer {idx text} {
if {[string tolower $text] == "i will not do bad things"} {
chattr [idx2hand $idx] -E
putdcc $idx "so soon? ok, youre back on the partyline"
setchan $idx 0
return
} {
putdcc $idx "nice try !"
return
}
}
proc chjn:enfer {bot hand chan flag idx from} {
if {$chan == "666"} {
if {![matchattr $hand m]} {chattr [idx2hand $idx] +E}
putdcc $idx "welcome in hell bad boy?"
putdcc $idx "you have two choices , you stay here with me or you say \"i will not do bad things\"... the choice is yours!"
}
}
proc chon:enfer {hand idx} {
setchan $idx 666
return
}
proc dcc:enfer {hand idx arg} {
set idx [hand2idx [lindex $arg 0] ]
if {[valididx $idx]} {
setchan $idx 666
return 1
} {
putdcc $idx "[lindex $arg 0] is not a valid partyline user."
return 0
}
}