egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

SpamKicker.tcl

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Support & Releases
View previous topic :: View next topic  
Author Message
AlIt0
Voice


Joined: 14 Apr 2010
Posts: 11

PostPosted: Sun Jul 17, 2011 1:24 pm    Post subject: SpamKicker.tcl Reply with quote

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
View user's profile Send private message
username
Op


Joined: 06 Oct 2005
Posts: 196
Location: Russian Federation, Podolsk

PostPosted: Mon Jul 18, 2011 3:53 am    Post subject: Reply with quote

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
View user's profile Send private message Send e-mail Visit poster's website
AlIt0
Voice


Joined: 14 Apr 2010
Posts: 11

PostPosted: Wed Jul 20, 2011 8:24 am    Post subject: Re Reply with quote

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
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Support & Releases All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber