Senior Member
Join Date: Jan 2013
Posts: 273
|
So I'm trying to figure out an Eval Script to increase # of dice at certain levels, like Superiority Dice. So I grabbed it's script...
~ Increase the number of dice at level 7 and again at 15 if (field[xAllLev].value >= 15) then field[trkMax].value += 2 elseif (field[xAllLev].value >= 7) then field[trkMax].value += 1 endif But when I try to use it in my boon, it tells me: Attempt to access field 'xAllLev' that does not exist for thing 'EP5CbnTidofWar' I for the life of me, cannot figure out the field tag for total character level. |
#1 |
Senior Member
Join Date: May 2016
Posts: 608
|
I thought the total level variable were only used for certain contexts, I can't remember the rule of thumb though.
There is a useful macro: #totallevelcount[] that you can use where the context is not right though: Here's the help example. ~ Check whether you're at least a 5th-level hero @valid = 0 if (#totallevelcount[] >= 5) then @valid = 1 endif There's a companion macro that narrows it down to a single class, but you need to know the class ID: ~ Check whether you have at least 5 levels of the Fighter class @valid = 0 if (#levelcount[Fighter] >= 5) then @valid = 1 endif |
#2 |
Senior Member
Join Date: Jan 2013
Posts: 273
|
I had found that macro and tried to simply substitute that in for the AllLev wording, and that hadn’t worked. I assumed it was because I wasn’t using the macro right.
How does that target the TrkMax value? Edit: NVM, I input that macro in place of the check for AllLev, and it worked perfectly. Thank you! Last edited by Brolthemighty; September 4th, 2020 at 08:16 PM. |
#3 |
|
|