| View previous topic :: View next topic |
| Author |
Message |
le0pard Voice
Joined: 22 Dec 2005 Posts: 1
|
Posted: Thu Dec 22, 2005 4:28 pm Post subject: procedure not being ran, :( |
|
|
| Code: | proc web:check {account} {
egghttp:geturl http://caleague.com/?page=calclub&standalone=1&authserv_account=[set account] web:verify
}
proc web:verify {sock} {
set headers [egghttp:headers $sock]
set body [egghttp:data $sock]
putlog "Body: $body"
if {![string match -nocase "Authserv account not in database" [set body]]} {
if {[string match -nocase *<division>* $body]} {
foreach line [split $body \n] {
if {[string match -nocase <division> $line]} {
lappend division $line
}
}
putlog "$division"
if {[string match -nocase #calclub-im $::invite(chan)} {
if {[string match -nocase csp $division] || [string match -nocase csm $division] || [string match -nocase csim $division]} {
puthelp "INVITE $::invite(user) #calclub-im"
puthelp "PRIVMSG $::invite(user) :You have been invited to join #CALClub-IM"
} else {
puthelp "PRIVMSG $::invite(user) :You are not CS 1.6 Intermediate+"
}
}
} else {
puthelp "PRIVMSG $::invite(user) :You are not currently in a CS 1.6 Division."
}
} else {
puthelp "PRIVMSG $::invite(user) :Your AuthServ account does not exist in the CAL database. Please edit your CAL user profile and wait up to 3 hours for the database to reset."
}
}
proc msg:inviteme {nick uhost handle text} {
if {[string match -nocase *@*.*.gamesurge $uhost]} {
if {[llength $text] == "2"} {
puthelp "PRIVMSG $nick :Checking your current leagues."
global invite
set invite(user) [set nick]
set invite(chan) [lindex $text 2]
set uhost2 [lindex [split $uhost @] 1]
set account [lindex [split $uhost2 .] 0]
web:check $account
} else {
puthelp "PRIVMSG $nick :Syntax Error. Correct Syntax: .inviteme #channel"
}
} else {
puthelp "PRIVMSG $nick :You must be using mode +x (Host Hiding) to be invited"
}
}
|
web:verify procedure isnt ever being ran - Is this something simple that I'm over looking? |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Thu Dec 22, 2005 8:23 pm Post subject: |
|
|
It is being called by the egghttp:geturl command. _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
|