Axe Software Forums
  Quest Developer Forum
  Help the newbie


Author Topic:   Help the newbie
babydragon posted 10-11-2001 22:19 GMT     
Quick question. After setting up a status variable (let's say "money" initialy set to zero), how can I have an taken object (5 dollar bill) add a numeric value to the "money" status variable (in this case 5)?
DarkAng3l posted 10-11-2001 22:43 GMT          
Allthough not knowing much about quest, try making the numeric value= numeric value + 5. (Don't take what i say for granted. Use the command change collectable in that logic)
DarkAng3l posted 10-11-2001 22:43 GMT          
Allthough not knowing much about quest, try making the numeric value= numeric value + 5. (Don't take what i say for granted. Use the command change collectable in that logic)
Tyrant posted 10-11-2001 23:51 GMT          
If money is your numeric variable, then:

set numeric <money; %money% +5>

If you are using QDK, go to Set Numeric Variable:

NAME: money
CONTENTS: %money% +5

Computer Whizz posted 11-11-2001 18:03 GMT          
Well, actually you only have to put:
set <money; %money% + 5>
as this is/should be used to "set" a variable which has already been declared!
a set numeric/string <money; 5> would declare a NEW variable (not all the time) and would set it to 5..... it would also work with changing an already declared variable.

Just thought everyone should know that ;)

Computer Whizz

Alex posted 11-11-2001 19:13 GMT          
Both "set numeric <money; %money%+5>" and "set <money; %money%+5>" will work the same, provided that "money" has already been declared, and presumably it has if you're incrementing it. The "numeric" part will tell Quest what sort of variable to create if it is new, and if it's not new it just helps Quest a bit - although it's not necessary.
babydragon posted 11-11-2001 22:16 GMT          
Thanks all, got that status variable stuff figured out. Now on to a new problem...