| View previous topic :: View next topic |
| Author |
Message |
Torrevado Op
Joined: 02 Aug 2006 Posts: 101
|
Posted: Sat Apr 21, 2007 6:07 am Post subject: eggdrop abuse |
|
|
Hi ,
I'd like a script to prevent commands flood (eggdrop commands). I mean eggdrop would kick (and give reason) people who use more than allowed number of request per minute. If a user has been kicked and rejoin asking the bot again before 1 minute, the user will be banned.
All commands are triggered with "!"
Thanks |
|
| Back to top |
|
 |
Alchera Revered One

Joined: 11 Aug 2003 Posts: 3344 Location: Ballarat Victoria, Australia
|
Posted: Sat Apr 21, 2007 11:44 pm Post subject: |
|
|
Tcl Archive _________________ Add [SOLVED] to the thread title if your issue has been.
Search | FAQ | RTM |
|
| Back to top |
|
 |
Torrevado Op
Joined: 02 Aug 2006 Posts: 101
|
Posted: Mon Apr 23, 2007 5:07 pm Post subject: |
|
|
Obviously there's no such script, otherwise this request wouldn't have been done
Thanks anyway  |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Mon Apr 23, 2007 6:32 pm Post subject: |
|
|
Read this topic and apply that proc given by user into your script (see the example code). _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
Torrevado Op
Joined: 02 Aug 2006 Posts: 101
|
Posted: Mon Apr 23, 2007 6:55 pm Post subject: |
|
|
Thanks, Sir_Fz
I guess I have to add that proc into every script, isn't it? |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Mon Apr 23, 2007 7:25 pm Post subject: |
|
|
It's enough to add it into one script, you can use it in all your procs as long as it is loaded. I guess user's example code is enough to teach you how to use the proc:
| user wrote: | | Code: | bind pub n !test pub:test
proc pub:test {n u h c a} {
if {[throttled $u,$c 30]} {
puthelp "PRIVMSG $c :$n: denied. (wait or try a different channel)"
} else {
puthelp "PRIVMSG $c :$n: allowed (wait 30 seconds)"
}
} |
|
_________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
|