This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.
For more information, see this announcement post . Click the X in the top right-corner of this box to dismiss this message.
Old posts that have not been replied to for several years.
Rob
Voice
Posts: 25 Joined: Thu Aug 01, 2002 1:21 pm
Post
by Rob » Fri Nov 14, 2003 8:48 am
ive just downloaded Anti Trout Slap v1.1 By Dude but noticed it bans anyone who does the trout slap. can it be modified to only ban non-opped users, so others like voice and non-voice/opped users will get punished for using trout slaps.
Code: Select all
proc antitrout:ctcp:action {nick uhost hand dest keyword arg} {
global botnick troutkickmethod troutkickreason troutbantime
if { [validchan $dest] == 1 && ([string tolower [lindex $arg 0]] == "slaps" || [string tolower [lindex $arg 0]] == "slap") && [lsearch [string tolower $arg] trout] >= 2 && [string tolower $nick] != [string tolower $botnick] && [botisop $dest] == 1 } {
if { $troutkickmethod == 0 && [string tolower [lindex $arg 1]] == [string tolower $botnick] } {
putserv "kick $dest $nick :$troutkickreason"
}
if { $troutkickmethod == 1 } {
putserv "kick $dest $nick :$troutkickreason"
}
if { $troutkickmethod == 2 && [string tolower [lindex $arg 1]] == [string tolower $botnick] } {
scan [string tolower [getchanhost $nick $dest]] "%\[^@]@%s" host host
newchanban $dest *!*@$host $botnick "$troutkickreason" $troutbantime
}
if { $troutkickmethod == 3 } {
scan [string tolower [getchanhost $nick $dest]] "%\[^@]@%s" host host
newchanban $dest *!*@$host $botnick "$troutkickreason" $troutbantime
}
}
return 0
}
putlog "Anti Trout Slap v1.1 By Dude \002Loaded...\002"
Any help would be great.
Rob.
Sir_Fz
Revered One
Posts: 3794 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Fri Nov 14, 2003 9:50 am
if {[isop $nick $dest]} {return 0}
Rob
Voice
Posts: 25 Joined: Thu Aug 01, 2002 1:21 pm
Post
by Rob » Fri Nov 14, 2003 10:08 am
Sir_Fz wrote: if {[isop $nick $dest]} {return 0}
and i would put that where?
sorry i aint too familar with tcl.
Sir_Fz
Revered One
Posts: 3794 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Fri Nov 14, 2003 10:14 am
under
Code: Select all
if { [validchan $dest] == 1 && ([string tolower [lindex $arg 0]] == "slaps" || [string tolower [lindex $arg 0]] == "slap") && [lsearch [string tolower $arg] trout] >= 2 && [string tolower $nick] != [string tolower $botnick] && [botisop $dest] == 1 } {
Rob
Voice
Posts: 25 Joined: Thu Aug 01, 2002 1:21 pm
Post
by Rob » Fri Nov 14, 2003 10:42 am
it still bans ops