simo wrote:i was wondering if eggdrop could cycle (part join like every 10 min)
and check for pms within like 5 sec of joining and if so to to set ban and kick
...
Try this:
Code: Select all
# June 13, 2020
#
# http://forum.egghelp.org/viewtopic.php?t=20793
#
###
bind cron - "*/10 * * * *" do_cycle
###
proc do_cycle {min hour day month weekday} {
bind msgm - "*" msg:bot
putserv "part #channel_name_goes_here"
utimer 5 [list unbind msgm - "*" msg:bot]
}
###
###
proc msg:bot {nick uhost handle text } {
## commands to kick/ban go here
}
###
This is un-tested.
The bind cron should accomplish your desire to do something every 10 minutes.
Reference:
https://crontab.guru/#*/10_*_*_*_*
You need to edit in the channel name to part. This thing is currently designed to be single channel. For now, see if you can get it to do what you want/need. Then, if you need it to work on more than one channel, maybe then we can doctor on it some more.
It does not actually check that the bot joined #channel, and then begin the 5 second countdown to unbinding. You can see the "5" in there, for now - and you can tweak that to suit.
However, if you find that you DO need it to watch for the bot itself joining, I suppose we could use a bind join for that, and re-write it.
Let's see what happens with this.
I hope this helps.
For a fun (and popular) Trivia game, visit us at: irc.librairc.net #science-fiction . Over 300K Q & A to play in BogusTrivia !