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.

TCL Flags

Help for those learning Tcl or writing their own scripts.
Post Reply
R
ReeVo
Voice
Posts: 2
Joined: Wed Jul 30, 2014 11:53 am

TCL Flags

Post by ReeVo »

Hello Ppls,

i have installed the module Blacklist.tcl from this site. I have some question about this script. Actually this script working on channel with BOT OWNER. I want to make the script work with OPS, ADMIN, HELPOP an IRCops also. What must i change on this code that this work probably?
Actually only the bot owner cant enter the following command .blist .

Code: Select all

bind PUB m|o \.blist blacklist:list
proc blacklist:list {nickname hostname handle channel arguments} {
global blacklist
set entrys 0
puthelp "NOTICE $nickname :Blacklist"
puthelp "NOTICE $nickname :Nr. Nick Ip/Host"
foreach entry [array names blacklist] {
incr entrys
set owner [lindex $blacklist($entry) 0]
while {[string length $owner] < 15} {
set owner "$owner"
}
if {[string length $entrys] < 2} {
set target "$entrys "
} else {
set target $entrys
}
puthelp "NOTICE $nickname :#$target $ops $entry"
}
puthelp "NOTICE $nickname :Sfarsitul Listei."
}
Thx for any help ;)
User avatar
Get_A_Fix
Master
Posts: 206
Joined: Sat May 07, 2005 6:11 pm
Location: New Zealand

Post by Get_A_Fix »

The subject body of this thread even tells you the answer you're looking for. It is the user flags that are inside the bind

Code: Select all

bind PUB m|o .blist blacklist:list
The m| is for Global Master, while the |o is for Channel Operator. User's that have flags higher than these are also able to trigger, like a Channel Master, or Owner. It will be fine adding in your main user's, for Global bot users and Channel based. As for allowing IRCops to trigger, this would require more editing and possibly using a RAW numeric to match/check if someone is /oper'd.

Please read the tcl-commands.doc file, inside your eggdrop/doc directory. This will give you information on built in commands and global variables you're able to use/call. The information regarding BIND is near the bottom. You can also find the tcl-commands.doc file online, a simple search of google will return ones from egghelp, eggheads and other prospective sources.

Good Luck :)
We explore.. and you call us criminals. We seek after knowledge.. and you call us criminals. We exist without skin color, without nationality, without religious bias.. and you call us criminals.
Post Reply