| View previous topic :: View next topic |
| Author |
Message |
Way2Death Voice
Joined: 31 Mar 2009 Posts: 15
|
Posted: Tue Mar 31, 2009 3:38 pm Post subject: Kicked user PM |
|
|
Hey all,
i would like to know if the following is possible.
When Q (quakenet bot) kicks/bans someone the bot sends a PM to the kicked/banned player containing some text. |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Tue Mar 31, 2009 4:11 pm Post subject: |
|
|
That shouldn't be too hard.
Q's kick should trigger the kick binding, just like anyone else. You'd then have to check whether it was Q that did the kicking or someone else.
The last part is simply a matter of using puthelp to send a msg to the target.
Rough example:
| Code: | proc Qkick {nick host handle channel target reason} {
if {[string equal -nocase $nick "Q"]} {
puthelp "PRIVMSG $target :You've been kicked by Q!"
}
} |
_________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
Way2Death Voice
Joined: 31 Mar 2009 Posts: 15
|
Posted: Tue Mar 31, 2009 4:36 pm Post subject: |
|
|
Thanks for your help, will test it out
hm a little question,
could that code be used, because will the tcl automatically start the if string or do i have to put something that will initiate it when someone gets kicked?
Edit; well it didn't work... i have no idea why not |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Tue Mar 31, 2009 4:59 pm Post subject: |
|
|
Ohh, sorry,
Forgot to add the binding...
| Code: | proc Qkick {nick host handle channel target reason} {
if {[string equal -nocase $nick "Q"]} {
puthelp "PRIVMSG $target :You've been kicked by Q!"
}
}
bind kick - * Qkick |
_________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
Way2Death Voice
Joined: 31 Mar 2009 Posts: 15
|
Posted: Tue Mar 31, 2009 5:15 pm Post subject: |
|
|
Thanks it works  |
|
| Back to top |
|
 |
|