Lawful_g, could you please edit your post to change the:
result = assign[]
statements to use:
perform assign[]
That's the current standard, and I'd rather not teach a new user the old way of doing it.
Also, X = X + Y (like your container[vRef] example, can be replaced with:
X += Y (or -=, *=, /+) to save a bit of typing.
The other usage of var is:
var XXX as string
which tells the compiler you want a string (letters and words) variable. That won't be used as much by the user, but is occasionally needed when you want to generate some text output.
Sorry to hit you again, but as a reminder, competence bonuses in d20 don't stack, so you shouldn't simeply add something to it.
There are macros available to help you with the non-stacking bonuses:
#enhancementbonus[
pick,
bonus]
#competencebonus[
pick,
bonus]
#applybonus[
type,
pick,
bonus]
#applypenalty[
type,
pick,
bonus]
In all those cases, pick is the reference of what you want to modify; hero.child[vRef] is the proper way to access the reflex save.
bonus is the new value, and type is the field you want to modify (which sort of thing it is), for example: BonComp, BonEnhance, BonMorale. For the complete list, open up the help page from your editor and go to the "Reference Information" link.
For your competence bonus example, you could either use:
Code:
#competencebonus[hero.child[vRef],bonus]
or
Code:
#applybonus[BonComp,hero.child[vRef],bonus]