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.

Anyone have tryed "popdog" BotRequest script from

Old posts that have not been replied to for several years.
Locked
R
RaBieZ|ZyFleX

Anyone have tryed "popdog" BotRequest script from

Post by RaBieZ|ZyFleX »

have anyone tryed that script ?
my wont work...
perhaps anyone can help me whit it ?

When ppl use the request command nothing happens...
but in the partyline the bot says:

Tcl error [pub:request]: can't read "botnicks": no such variable

I have set the bot nicks... what can be wrong ?
P
Photon
Op
Posts: 170
Joined: Wed Aug 28, 2002 8:00 am
Location: Liverpool, England

Post by Photon »

There is a standard variable called 'botnick', but not 'botnicks' - is this a typo?
R
RaBieZ|ZyFleX

.

Post by RaBieZ|ZyFleX »

im not sure i understand what you mean... i cant find any place in the script where there only are typed botnick
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

My advice is to read over the configuration of the script carefully, as you may have left out a setting, that can't be blank, or has a invalid format.

While it may not be directly named the same as in the error, missing data elsewhere could cause this to happen.

Another cause is, that you have missed a setting in the main config file. Which config template did you use.
R
RaBieZ|ZyFleX

k

Post by RaBieZ|ZyFleX »

I used the advanced one...

im checking the tcl again... im almost sure im not gonna find any errors.... im a n00b in tcl... :/
perhaps you will check it for me if i post it here ?
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

If you post a link to the script, I will look over it.
R
RaBieZ|ZyFleX

the script

Post by RaBieZ|ZyFleX »

Thanks :D


# BotRequest by popdog <Humpert.Ben@T-Online.de>, #Q-Control @ QuakeNet
# version 1.3 for eggdrop 1.5.x & 1.6.x
# 05-Nov-2001
# If you have suggestions -> #Q-Control @ QuakeNet

# some settings

set botnicks "ZyFleX01 ZyFleX02"
# Enter every bots nickanme which is free for requesting.
set waittime "3800"
# Enter time in seconds the user have to wait before he can request again. (default "604800" = 1 week)
set receiver "$owner"
# Enter handle (or use $owner if the bot-owner shout receive it) of added user which should receive the request. If note should send to an user on another bot use handle@botname. (default "$owner")
# more users can be added if you remove the "#" in front of the line below


# YOU SHOULDN'T EDIT ANYTHING BELOW THIS LINE IF YOU DON'T KNOW WHAT YOU ARE DOING !!

bind pub -|- !request pub:request

proc pub:request {nick uhost handle chan text} {
set ipmask [lindex [split [maskhost $nick![getchanhost $nick $chan]] "@"] 1]
set userm [lindex [split [getchanhost $nick $chan] "@"] 0]
set userhost *!*$userm@$ipmask
set requestbot [lindex [split $text " "] 0]
set channel [lindex [split $text " "] 1]
set homepage [lindex [split $text " "] 2]
if {[matchattr $handle +R]} {
putserv "NOTICE $nick :Request not send."
putserv "NOTICE $nick :You already requested a bot in the last 7 days!"
putserv "NOTICE $nick :You have to wait more than 7 days after a successful Request."
} else {
if {$requestbot == ""} {
putserv "NOTICE $nick :Wrong !request-format."
putserv "NOTICE $nick :To request use: 4!request <bot-nick> #channel http://www.home.page"
putserv "NOTICE $nick :You also need a working homepage and 2 or more Members opped in the requested channel."
} else {
if {$channel == ""} {
putserv "NOTICE $nick :Wrong !request-format."
putserv "NOTICE $nick :To request use: 4!request <bot-nick> #channel http://www.home.page"
putserv "NOTICE $nick :You also need a working homepage and 2 or more Members opped in the requested channel."
} else {
if {[string first "#" $channel] == -1} {
putserv "NOTICE $nick :Wrong !request-format."
putserv "NOTICE $nick :To request use: 4!request <bot-nick> #channel http://www.home.page"
putserv "NOTICE $nick :You also need a working homepage and 2 or more Members opped in the requested channel."
} else {
if {[string first "http://" $homepage] == -1} {
putserv "NOTICE $nick :Wrong !request-format."
putserv "NOTICE $nick :To request use: 4!request <bot-nick> #channel http://www.home.page"
putserv "NOTICE $nick :You also need a working homepage and 2 or more Members opped in the requested channel."
} else {
if {[string first $requestbot $botnicks] != -1} {
if {$channel != ""} {
if {$homepage != ""} {
sendnote BotRequest $receiver "$nick want's $requestbot in $channel. His HP is $homepage."
# sendnote BotRequest user1 "$nick want's $requestbot in $channel. His HP is $homepage."
# sendnote BotRequest user2 "$nick want's $requestbot in $channel. His HP is $homepage."
adduser $nick $userhost
chattr $nick +R|
utimer $waittime "chattr $nick -R|"
putserv "NOTICE $nick :Request send."
} else {
putserv "NOTICE $nick :Wrong !request-format."
putserv "NOTICE $nick :To request use: 4!request <bot-nick> #channel http://www.home.page"
putserv "NOTICE $nick :You also need a working homepage and 2 or more Members opped in the requested channel."
}
}
} else {
putserv "NOTICE $nick :You typed a wrong bot-nick. Known bot-nick's are:"
putserv "NOTICE $nick :$botnicks"
}
}
}
}
}
}
}

putlog "BotRequest v1.3 by popdog loaded."
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

Locate this line

Code: Select all

proc pub:request {nick uhost handle chan text} {
and make it

Code: Select all

proc pub:request {nick uhost handle chan text} {
global botnicks
(yes it is 2 seperate lines)

I don't know if there are any other errors.
R
RaBieZ|ZyFleX

!

Post by RaBieZ|ZyFleX »

hmm now that error are gone, but a new come :/

Tcl error [pub:request]: can't read "receiver": no such variable

can you help again ? :)
User avatar
Papillon
Owner
Posts: 724
Joined: Fri Feb 15, 2002 8:00 pm
Location: *.no

Post by Papillon »

Code: Select all

global botnicks
change this line to:

Code: Select all

global botnicks receiver waittime
when a variable is set outside a proc you have to put it in the global line to be able to use it inside a proc
Elen sila lúmenn' omentielvo
R
RaBieZ|ZyFleX

great

Post by RaBieZ|ZyFleX »

thanks :D
It work now :D
Locked