| View previous topic :: View next topic |
| Author |
Message |
AlIt0 Voice
Joined: 14 Apr 2010 Posts: 11
|
Posted: Sun Jul 17, 2011 1:24 pm Post subject: SpamKicker.tcl |
|
|
| Code: | bind bot Z kb kbspam
proc kbspam {botnc kb inviter} {
global kb_reason ban_time exflag dkick
set nick [lindex $inviter 0]
set bmask [lindex $inviter 1]
set host "$nick![getchanhost $nick]"
set dmask [maskhost $uhost]
set nickhand [nick2hand $nick]
if {[string match $ban $botname] == 0} {
if {[string match "*html.chat" $uhost]} { set ban "*!*[lindex [split [maskhost $uhost] "!"] 1]" } { set ban "*!*@[lindex [split $uhost "@"] 1]"}
return 0
}
putlog "makes invites <<|$botnc|>>-> $bmask"
putlog "Ban/Kicking $bmask from channels..."
foreach chan [channels] {
if {[onchan $nick $chan] == 1} {
putquick "KICK $chan $nick :[censored] inviter"
putserv "MODE $chan +b :$dmask"
return 0
}
# newban $fmask chek3r $dkick 0
newchanban $chan $nick chek3r "$nick is a stewpid inviter" $ban_time
}
}
putlog "spam kicker running."
|
Tcl error [kbspam]: can't read "uhost": no such variable
Will you tell me what to replace "uhost" |
|
| Back to top |
|
 |
username Op

Joined: 06 Oct 2005 Posts: 196 Location: Russian Federation, Podolsk
|
Posted: Mon Jul 18, 2011 3:53 am Post subject: |
|
|
I think $uhost equal to | Code: | | set host "$nick![getchanhost $nick]" |
Try to change $uhost to $host or | Code: | | set host "$nick![getchanhost $nick]" | to | Code: | | set uhost "$nick![getchanhost $nick]" |
_________________ Архив TCL скриптов для ботов Eggdrop/Windrop:
http://egghelp.ru/ |
|
| Back to top |
|
 |
AlIt0 Voice
Joined: 14 Apr 2010 Posts: 11
|
Posted: Wed Jul 20, 2011 8:24 am Post subject: Re |
|
|
Yup, changed as he wrote, but now I have this problem
[15:47] <(Linux> [15:45] Tcl error [kbspam]: can't read "ban": no such variable |
|
| Back to top |
|
 |
|