| View previous topic :: View next topic |
| Author |
Message |
helperis Voice
Joined: 09 Apr 2008 Posts: 5
|
Posted: Wed Apr 09, 2008 8:54 am Post subject: enforce bans |
|
|
I need script like +enforce bans. But i need to bot in kick message write not (Banned) but (Banned by nick -KICK COUNT-)
There is something but don't working:
| Code: | bind mode - * mode_proc
proc mode_proc {nick uhost hand chan mode target} {
#need kick counter code:
set kickcount 0
if {[botisop]} {
if {$mode eq "+b"} {
putkick $chan $nick "\(banned by \002$nick\002 -${kickcount}-\)"
}
} else {
putserv "PRIVMSG $chan :I'm not op'd!";
} |
Sorry for my english  |
|
| Back to top |
|
 |
YooHoo Owner

Joined: 13 Feb 2003 Posts: 939 Location: Redwood Coast
|
Posted: Wed Apr 09, 2008 8:56 am Post subject: |
|
|
There are several kick counter scripts in the archives, maybe you might wanna give one of them a go  _________________
Johoho's TCL for beginners
 |
|
| Back to top |
|
 |
helperis Voice
Joined: 09 Apr 2008 Posts: 5
|
Posted: Wed Apr 09, 2008 9:43 am Post subject: |
|
|
first i need:
on channel ban to bot enforce banned user and kick him with message
(banned by nick)
kick counter later
And maybe i need go to "script requests" forum?  |
|
| Back to top |
|
 |
helperis Voice
Joined: 09 Apr 2008 Posts: 5
|
Posted: Wed Apr 09, 2008 1:27 pm Post subject: |
|
|
Thanks forum.egghelp.org
if anyone need this script:
| Code: | set kickcount 0
proc countkicks {} {
incr ::kickcount
}
bind mode - "* +b" enforcebans
proc enforcebans {nick uhost hand chan mc ban} {
if {![string match -nocase [string map {"\\" "\\\\" "\[" "\\["} $ban] $::botname]} {
foreach n [chanlist $chan] {
if {[string match -nocase [string map {"\\" "\\\\" "\[" "\\["} $ban] $n![getchanhost $n $chan]]} {
putkick $chan $n "Banned by \002$nick\002... - [countkicks] -"
}
}
} else {
pushmode $chan -o $nick
}
}
|
|
|
| Back to top |
|
 |
|