Well, you cannot precede just any kick, no. But most of the kicks on eggdrop (not counting those done by extern TCL scripts) are triggered by flood. If you read doc/tcl-commands.doc and search for "bind flud" you'll find that it is triggered *before* the usual eggdrop's processing routine. So, there you may put whatever procedure you want. Note that you can return from with with 0 or 1 to achive different post behaviour.
As for kick counter, there is "bind kick" which would trigger on any kick that occured.
STOP THE PRESS
Breaking News: Eggdrop is GPL so any code or docs with it are free to be used. Please do some reading.
Ignorant and lazy people will save 30 minutes by chosing simple config file. Smart ones will save 3000 minutes of *everyone's* time by opting for complete config file.
I use xtreme for my mirc script. when you kick, it puts the kick msg then ban counter in the kick msg.. thats what I want to do, put a ban counter write into the kick msg on ever kick I do...
Custom script for mIRC does custom kicks with counter within reason part. Custom script for eggdrop will do the same, only you need to make it or find it. In case you decide to make it, keep in mind that bind kick *would* work. Infact, that would be the easiest way to track your own kicks.
bind flud would on the other hand be the easiest way to stop eggdrop doing it's job but instead passing control over the current punishemnt method, message, blah, whatever - to you. Only potential problems are non sticky bans that are not on channel but in bots userlist and will become active once user rejoins. But even that part should be possible to work around by using var names in ban reasons. Tho, i am not 100% sure if eggdrop will for some wierd reason prevent you from doing that (it shouldnt).
Ignorant and lazy people will save 30 minutes by chosing simple config file. Smart ones will save 3000 minutes of *everyone's* time by opting for complete config file.
I got that part. I would also have to save it to a file for when the bot goes down. I am gonna write a script to test some theories I and darko have. Just from the documentation saying that kick bind works after a kick happends. Plus, in the event, I will be changing the kick msg as well, and I don't see how thats gonna happen from what I see...
There is no way to detect when a kick is about to happen, either from antoher client or from eggdrop.
Until the kick happens, any client (eggdrop is a automated client), does not it has or will happen. On top of this, thbere is no way to tell the IRC server to change the message. You would need some form of IRCD service for this (which eggdrop is not).
Af for knowing is eggdrop is about to make a kick, you caqn replace the puthelp, putserv, putquick, putkick commands, using tcl, and detect if a script is about to make one.
tradergt, just to make my self even more clear: bind kick will help you know what will be the value of the counter for your *next* kick. First kick you allready know will be = 1 So:
set kickcnt 1
bind kick.. {incr kickcnt}
bid flud.. {check what flood type and putkick with "Kicked for some-type-of-flood, kick No. $kickcnt}
You may wonder why bind kick to increase kickcnt when you can simply increase it right after your putkick. Well, someone else could have allready kicked the user that very momment, and eggdrop will still increase kickcnt even tho it wasn't your bot tht made a kick.
Ignorant and lazy people will save 30 minutes by chosing simple config file. Smart ones will save 3000 minutes of *everyone's* time by opting for complete config file.
err, bind kick should actually check if it was your bot that executed a kick and only then incr kickcnt
Ignorant and lazy people will save 30 minutes by chosing simple config file. Smart ones will save 3000 minutes of *everyone's* time by opting for complete config file.