egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Unban last ban.

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests
View previous topic :: View next topic  
Author Message
Getodacul
Voice


Joined: 07 Jun 2007
Posts: 20

PostPosted: Mon Sep 22, 2008 3:36 pm    Post subject: Unban last ban. Reply with quote

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.
Back to top
View user's profile Send private message
smash
Halfop


Joined: 31 Jul 2006
Posts: 45

PostPosted: Wed Sep 24, 2008 9:25 am    Post subject: Reply with quote

http://www.egghelp.org/tclhtml/3478-4-0-0-1-last-ban.htm
_________________
quakenet #fraguk www.fraguk.com
hosting 113 scripts @ this time!
Back to top
View user's profile Send private message
Getodacul
Voice


Joined: 07 Jun 2007
Posts: 20

PostPosted: Thu Sep 25, 2008 9:49 am    Post subject: Reply with quote

That's the script:

Quote:

#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."
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber