botlending forum  

Go Back   botlending forum > Eggdrop & TCL > Tcl scripting

Tcl scripting Tcl scripting related questions

Reply
 
LinkBack Thread Tools Display Modes
Old 12-11-2004, 13:43   #1 (permalink)
fky
Junior Member
 
Join Date: Nov 2004
Posts: 1
Rep Power: 0
fky is an unknown quantity at this point
Unhappy tot despre masca

Code:
 
proc call_adduser {nick handle chan misc1 misc2 misc3} {
global home groupname botnick numversion strict-host levels
if {$misc1 == ""} { 
notice $nick "Usage: (/msg) $botnick adduser (#channel) <nick> <friend | voice | bot | op | master | owner | full | bot | chanvoice | chanowner | chanmaster | chanop>"
notice $nick "See also : (/msg) $botnick levels"
	return 0
}
if {$misc2 == ""} {notice $nick "You need to specify a level. Try: (/msg) $botnick levels" ; return 0}
set available [string tolower "bot $levels"]
if {[lsearch -glob $available [string tolower $misc2]] == -1} {notice $nick "$misc2 doesn't exist, you idiot!"; return 0}
set strict 0
if {[string index $misc1 0] == "!"} {set misc1 [string range $misc1 1 end]; set strict 1}
if {![onchan $misc1 $chan]} {notice $nick "$misc1 is not on $chan."; return 0}
set addhost [getchanhost $misc1 $chan]
if {![set strict-host] && ($strict == 0)} {
# Check for "strict-host / ~" issue in eggdrop 1.4.3+
if {[string index $addhost 0] == "~"} {set addhost "*[string range $addhost 1 end]"}
}
set checkhandle [nick2hand $misc1 $chan]
if {$checkhandle == "" || $checkhandle == "*"} {set checkhandle $misc1}
set checkhandle [string range $checkhandle 0 11]; if {$numversion < 1060900} {set checkhandle [string range $checkhandle 0 8]}
if {$strict == 0} {set addhost [maskhost $addhost]
} else {set addhost "*!$addhost"}
..... etc ... ideea e cum fac sa ia bine masca in cazul /mode x ca eu is varza

Last edited by UniversaliA; 12-11-2004 at 17:12. Reason: orice cod sa pui te rog intre [code] *** [/code]
fky is offline   Reply With Quote
Old 12-11-2004, 17:21   #2 (permalink)
Administrator

aka aqwzsx
 
Join Date: Jun 2004
Posts: 827
Blog Entries: 126
Rep Power: 3
UniversaliA is on a distinguished road
Default

Code:
if {$strict == 0} {set addhost [maskhost $addhost]}
schimbi in
Code:
 
if {[string match -nocase *@*.users.undernet.org $addhost]} {set addhost "*!*[join [regexp -inline -- {@[^@].+} $uhost]]"} elseif {
$strict == 0} {set addhost [maskhost $addhost]}
UniversaliA is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT +3. The time now is 07:20.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.