View Single Post
rob
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 8,232

Old March 8th, 2006, 03:29 PM
Both of these situations are referring to an actual "unit stat". Do you have a unit stat named "heroiclim"? Or is that just a tag you defined?

If it's a unit stat, they just swap in the name of your unit stat for the sample unit stat. In other words, replace "PtsMax" with "heroiclim".

Given that "heroiclim" is 9 characters long, I'm guessing it's just a tag and not an actual unit stat. If it were a unit stat, it would get truncated after only one digit of value, so that's not a good thing. The example assumes you are working with an actual "unit stat" value, which allows you to easily define a different value for each unit if you want.

Hope this helps,
Rob

At 03:29 PM 3/8/2006, you wrote:

Quote:
I'm having trouble figuring this out:

val:stat.PtsMax > 0

What should stat.PtsMax be? I thought if the stat was heroiclim, that line should be val:heroiclim.PtsMax, but that won't compile...



var unspent as number
unspent = unit.stat[PtsMax] - unit.stat[PtsUsed]

Same problem here, what exactly is unit.stat[PtsMax], and what is unit.stat[PtsUsed]?
rob is offline   #2 Reply With Quote