View Single Post
  #8  
Old 02-08-2004, 02:32 PM
Scorpious2k's Avatar
Scorpious2k
Demi-God
 
Join Date: Mar 2003
Location: USA
Posts: 1,067
Default

Quote:
Originally Posted by smogo
there might be a thing in the setglobal code, where duration is arglist[3], and referd to as arglist[2]. This causes wrong expiry result
You're right. It's fixed and will be right in the next release. And your fix was exactly right.

Quote:
Quote:
setglobal error inserting singer : DBcore::RunQuery: No Result
this does not seem to prevent insertion, but is confusing. Mybe this is an issue, i don't know what dbcore does exactly (and don't plan to check if possible). Any ideas ?
I haven't seen that one yet. Not sure what's going on...

Quote:
next time the event is triggered, the variable is not defined (test with 'if defined $varname' returns false) and quest::say("value of varname is " . $varname); prints "value of varname is :". I'm in the tracing of this at the moment. Could it be $quest::varname, or $questNNNN::varname or even $main::varname or ... ?
If you want it to be $varname, you have to set it as

Code:
quest::setglobal("varname",...
Don't include the $ in the name in setglobal. Also make sure the name is a valid perl var name. You can confirm it by checking the db and making sure it is there. name should always be the same as the variable name without the leading $.

Quote:
BTW, when setting a variable, it is not yet available (requires to re-enter the event).
You can always start out saying $varname = "myval"... use it thru the quest, and when you set it say

Code:
quest::setglobal("varname",$varname,...
That way it will be set to the current value (at the time the setglobal is done) for the next event. Maybe do this at the end of the event that initially creates it and each event where it is potentially changed.
__________________
Maybe I should try making one of these servers...
Reply With Quote