mob
var
HP = 30 //declares a new variable called HP, with a value of 30
usr.wealth += amount //add to usr.wealth
Problem description:7: Inconsistent indentation.
Please help, last part of Zilal's tutorial and it's annoying me that it wont work.
ID:263267
Aug 16 2006, 12:45 am
|
|
Code:
mob Problem description:7: Inconsistent indentation. Please help, last part of Zilal's tutorial and it's annoying me that it wont work. |
Aug 16 2006, 7:51 am
|
|
well first of all, the usr.wealth += amount shouldn't be indented under your declaration of HP. It should be wherever you want to add the amount to their wealth. Also, is wealth defined as a variable?
|
To use any sort of procedure or arithmetic or anything, you need to do it inside of a verb or "proc".
mob/var |
In response to CaptFalcon33035
|
|
I would add "as num" there.
|
In response to CaptFalcon33035
|
|
CaptFalcon33035 wrote:
To use any sort of procedure or arithmetic or anything, you need to do it inside of a verb or "proc". Correct, with the exception that in a proc, he shouldn't use usr. Lummox JR |