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.
Old posts that have not been replied to for several years.
T
TriPpen^KiSs
Post
by TriPpen^KiSs » Thu Feb 21, 2002 11:20 am
I have been scripting for a while and are getting some upgrades to my bot (the harder stuff).. I made a Auth System for my bot and when the person parts a chan it Deauths them..
coding
proc part_deauth {nick uhost hand chan} {
global homechan botnick
if { $hand == "*" } { return 0 }
if {([getuser $hand XTRA auth] == "0") || ([getuser $hand XTRA auth] == "DEAD")} {return 0}
setuser $hand XTRA AUTH 0
set tmphost "*![getuser $hand XTRA USERHOST]"
delhost $hand $tmphost
puthelp "PRIVMSG $homechan :[02Deauth02] - 02[02$nick!$uhost02]02 Parted All Deauthentication successfully"
putcmdlog "<<$nick>> ($uhost) !$hand! Temporary hostmask $tmphost removed."
save
}
}
Now what i am trying to do (and have noidea) is that i am trying to make the bot check to see if the person is still in one of the bots chan (so that it don't deauth them untill they have left all chans that the bot is in) I would love anyhelp that people can give me..
Thanx Adz
M
Misho
Post
by Misho » Fri Feb 22, 2002 10:17 pm
I'm not sure but try this:
proc part_deauth {nick uhost hand chan} {
global homechan
if { $hand == "*" } { return 0 }
if {([getuser $hand XTRA auth] == "0") || ([getuser $hand XTRA auth] == "DEAD")} {return 0}
set ostava 0
foreach kanal [channels] {
if {($kanal != $chan) && ([onchan $nick $kanal])} { set ostava 1 }
}
if {$ostava == 0} {
setuser $hand XTRA AUTH 0
set tmphost "*![getuser $hand XTRA USERHOST]"
delhost $hand $tmphost
puthelp "PRIVMSG $homechan :[02Deauth02] - 02[02$nick!$uhost02]02 Parted All Deauthentication successfully"
putcmdlog "<<$nick>> ($uhost) !$hand! Temporary hostmask $tmphost removed."
save
}
}
T
TriPpen^KiSs
Post
by TriPpen^KiSs » Sat Feb 23, 2002 8:28 am
Thanx i stayed up working on it till 4am... All works now
T
TriPpen^KiSs
Post
by TriPpen^KiSs » Mon Feb 25, 2002 5:39 am
Just another bug...
set adminlevel [getuser $nick XTRA ADMIN]
if {($adminlevel <= "200" && $adminlevel >= "500")} {
puthelp "PRIVMSG $homechan :[02Admin02] - $hand02[02$nick!$uhost02]02 $adminlevel Administrator"
}
I am trying to make the bot check the user file for the XTRA ADMIN level.. then check to see if it is not < 200 or > 500. then make to say the command... But it not working. Anyone help.
Kissmine
M
Misho
Post
by Misho » Mon Feb 25, 2002 10:28 pm
set adminlevel [getuser $nick XTRA ADMIN]
if {($adminlevel >= "200" && $adminlevel <= "500")} {
puthelp "PRIVMSG $homechan :[02Admin02] - $hand02[02$nick!$uhost02]02 $adminlevel Administrator"
}
T
TriPpen^KiSs
Post
by TriPpen^KiSs » Mon Mar 04, 2002 11:04 am
I have made a script that adds a XTRA for when a person is suspend for the reason...
Eg. XTRA SUSPEND <reason>
Now i am after a command that when you unsuspend a person that it removed the XTRA from the userfile.. is there anyway to do it??
Thanx Kissmine
Petersen
Owner
Posts: 685 Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK
Post
by Petersen » Mon Mar 04, 2002 11:46 am
iirc, setting its value to a null length string (ie "") should clear it.