This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Ban user between a specific time

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
h
hihachi
Voice
Posts: 2
Joined: Mon May 22, 2006 8:35 pm

Ban user between a specific time

Post by hihachi »

Hi everyone,

is there a way to create a script, which would kick users only when the join the channel on a specific time.

Example: User abc would like to be kicked from the channel from 09 am to 09 pm, as he should really work.
and if he joins after 9m to 8:59am the bot should not kick him.

It would be enough to state a time (like 98 m to 9 pm) and the option to kick only users with a specific flag on the bot. Like K for kick.

Is this possible??

Any help appreciated..


Greetz

Matz
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Code: Select all

bind join K|K * kickK

proc kickK {nick uhost hand chan} {
 foreach {h m} [split [strftime %R] :] {break}
 if {[scan $h %d] >= 9 && [scan $h %d] <= 20} {
  putquick "kick $chan $nick :reason"
 }
}
h
hihachi
Voice
Posts: 2
Joined: Mon May 22, 2006 8:35 pm

Post by hihachi »

Thanks..

how do i state the reason??
and is it possible to create a ban..and this only from mondays to fridays?? :)


Thanks in advance.. =)
Post Reply