I don't know how to do this with a TCL script, but its possible to do using the config file:
Unfortunatly, i do not use dalnet and so i don't know what sort of commands is used for unbanning, but on KnightNet I use the following in my chan information in the config file:
of course, to do this the bot must already be identifyed to nickserv (tell it to in the init-server bit of the conf. With a slight bit of tailoring with that you should be able to use it.
Hope this helps you.
Good Luck.
Karl (EvilPhish)
later on......there are many scripts avaliable for this kind of thing. check slennox's script archive
Simply copy/paste it in to a tcl file and load it to your bot, then do a .chanset #channel +myneeds where #channel is the channel(s) where you want it to interact with Chanserv.
Oh, as for weird ban thing.. duno what to say. I've deoped it, then placed a ban on its mask then oped it back. He didn't removed the ban that matches him weird..
Once the game is over, the king and the pawn go back in the same box.
bind mode - * op:mode
proc op:mode {nick uhost hand chan mc ban} {
global botnick botname
foreach ban [chanbans $chan] {
set mask [lindex $ban 0]
if {[string match "$mask" "$botname"]} {
putquick "MODE $chan -b $ban"
}
}
}
The eggdrop has it's own buit in mechanism to unban itself if has ops in the channel so there will be needed only the +o bind mode. When he is oped pn channel he will do a compare on each channel bans against it's mask and unban it if matches him.
Here is another code with binds for '+b' and '+o' if anyone needs it or something..