• 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

Timing of Eval Scripts

pippin_nl

Well-known member
I have 2 templates:'

TemplateA
TemplateB

template A has the following at first/530
field[tmHitDice].value += 3

template B has the following at first/535
if (#hastemplate[tmTemplateA] = 1) then
field[tmHitDice].value += 3

only TemplateA adds any Hit Dice, what am I doing wrong? I have tried the following already:

name TemplateA/eval script: Template_A
set TemplateB/eval script after Template_A
 
Last edited:
#hastemplate[tmTemplateA] checks for a tag that isn't added until much later than first phase. In this case, you probably want to check if the template is live:

Code:
if (hero.childlives[tmTemplateA] <> 0) then
  DO WHATEVER
  endif
 
#hastemplate[tmTemplateA] checks for a tag that isn't added until much later than first phase. In this case, you probably want to check if the template is live:

Code:
if (hero.childlives[tmTemplateA] <> 0) then
  DO WHATEVER
  endif

Thank you, that works!
 
Back
Top