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.
Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Getodacul
Voice
Posts: 20 Joined: Thu Jun 07, 2007 2:32 pm
Post
by Getodacul » Mon Sep 22, 2008 3:36 pm
I need a script who can unban the last ban on !unban command(on public channel or private). My realy problem is how to make the eggdrop to know what is the last ban.
smash
Halfop
Posts: 45 Joined: Mon Jul 31, 2006 12:33 pm
Post
by smash » Wed Sep 24, 2008 9:25 am
Getodacul
Voice
Posts: 20 Joined: Thu Jun 07, 2007 2:32 pm
Post
by Getodacul » Thu Sep 25, 2008 9:49 am
That's the script:
#Note: This script works of all the channels the bot is on.
##############################################################################
##############################################################################
bind pub o "unban" unban:pub
proc unban:pub {nick uhost hand chan text} {
global botnick
if {![botisop $chan]} {
putserv "PRIVMSG $chan :I'm not opped!"
} else {
set chanbanlist [lsort -index 2 -integer -decreasing [chanbans $chan]]
set last [lindex [lindex $chanbanlist end] 0]
if {[llength $chanbanlist] > 0} {
putquick "MODE $chan -b $last"
return 0
}
}
}
putlog "Unban last ban loaded successfully."