|
-
May 26th, 2003, 01:07 AM
#1
Eggdrop TCL
Does anyone know the TCL syntax for getting the bot to kick a user? so far ive tried:
Code:
bind pub - !kick kick
proc kick {nick uhost handle chan args} {
putserv "PRIVMSG $chan /kick $nick :\001ACTION die \001"
return 0
}
But all the bot does is return to the channel:
botname: /kick
instead of kicking the user upon request of !kick
...
I dont understand why not, it seems like it should work.. any input would be cool ..
-
May 26th, 2003, 10:04 AM
#2
bind pub - !kick kick
proc kick {nick uhost handle chan args} {
putserv "PRIVMSG $chan /kick $nick :\001ACTION die \001"
return 0
}
"PRIVMSG $chan" is RFC1459 speak for "send <this> to <channel>", hence the bot messaging the channel with /kick etc etc. remove this bit and it should work fine and dandy, eg;
bind pub - !kick kick
proc kick {nick uhost handle chan args} {
putserv "KICK $chan $nick :\001ACTION die \001"
return 0
}
(the / is not required on KICK because you are seding the command directly to the server - the slash is utilised by common clients. also note that i added a $chan before $nick, in accordance with RFC1459.)
cheers,
Abtronic
-
May 26th, 2003, 03:11 PM
#3
danke, im new to Tcl, thanks for da help
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|