• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

Changing bonus type

Kaleb

Well-known member
I would like to change the bouns type from tacDodge to sacred as Mark Seifer said that it would not be a good idea to have a dodge bonus as they stack with one another.

~ If we're equipped, add an armor bonus
if (field[gIsEquip].value <> 0) then
hero.child[ArmorClass].field[tACDodge].value += field[abValue].value
Endif

would the bolded text for Sacred be tacSacred?
 
In the editor, in the Help menu, choose "Help on using the editor", and then follow the "Reference Information" link, and then "General Modifiers".
 
Mathais where do I insert the BonSacred in the script

~ If we're equipped, add an armor bonus
if (field[gIsEquip].value <> 0) then
hero.child[ArmorClass].field[tACMisc].value += field[abValue].value
Endif

do I put the BonSacred after the field[tACMisc].value?
 
BonSacred is a non-stacking bonus, so you can't use a += to apply it. Instead, look somewhat above that section of that page, and find the "#applybonus" macro, and use that instead.
 
I am getting this error for the script below
Hero Lab was forced to stop compilation after the following errors were detected:

Syntax error in 'eval' script for Thing 'ioBoSA4' (Eval Script '#1') on line 4
-> Non-existent thing 'tACMisc' used by script
pre levels 5000 1
~ If we're equipped, add an armor bonus
if (field[gIsEquip].value <> 0) then
#applybonus[BonSacred, hero.child[tACMisc],4]
endif
 
Last edited:
Let me break some of the above down...

hero.child[ArmorClass].field[BonSacred].value
hero.child[] = the Pick the that is live on the hero that has fields.
field[] = the individual field/value stored on the "Pick".
.value = this means the "field" is to be treated as a number. You can also have ".text" that tells hero lab to treat the field as a string.

The #applybonus[field, pick, bonus] macro is:
field = Which "Field" do you want to give a bonus too?
pick = Which "Pick" has the associated field you wish to give a bonus too.
bonus = The amount of bonus to apply to the "field".
 
Tim and Mathias, thanks for you help I got it working. I looked back ocer another script that I made for a diffrent feat and changed the field asscioated with the bonus I wanted.
 
Back
Top