Simple-ish Bot idle part iv used in past bot projects, does the job for most cases needed, can change the time and the message
Just replace all the #'s with the channel you want aka staff chan if your into that sort of thing
Or change the alias staffchan return #channelhere with ur chan
All goes into a Remote file (Alt+R)
Any questions/suggestions to make it more efficient just post please :)
;The Trigger
on $*:TEXT:/^[.!@]Idle/Si:#chanhere: {
msg $staffchan Now parting all idle channels
idlepart
}
;The Actual script
alias idlepart {
var %x $chan(0)
while (%x) {
if ($nick($chan(%x),$me).idle > 86400) {
if (!$istok(#chan1 #chan2,$chan(%x),32)) {
Part $chan(%x) Idle for 1 Day or more. If you believe this was a mistake please reinvite.
msg $staffchan Parting $chan(%x) because of idle time: $duration($nick($chan(%x),$me).idle)
}
}
dec %x
}
}
;The alias for $staffchan
alias Staffchan return #channelhere