What I had above if you copied it and pasted it into a .user file would have shown up on the Adjustments tab, under Other. It was written as an adjustment.
If you want a feat, you have to use a different set of variables on the setup, you would use usrCandid1 instead of pCandExpr and userChosen instead of pChosen. Adjustments use different variables than feats.
Timing side I put it Post-level 10000, It could probably go anywhere before Final though. This is what it looks like as a self-contained feat:
<thing id="fXXXAddHDF" name="Added HD Feat" description="This feat adds a HD to the in-play tab." compset="Feat" uniqueness="useronce">
<fieldval field="usrCandid1" value="DiceSize.? & Helper.HitDieShow"/>
<tag group="Helper" tag="ShowSpec"/>
<tag group="ChooseSrc1" tag="Hero"/>
<tag group="User" tag="NoAutoName"/>
<eval phase="PostLevel" priority="10000"><![CDATA[ ~ If we're not enabled, get out now
doneif (field[usrChosen1].ischosen = 0)
~ Add to the chosen hit die
field[usrChosen1].chosen.field[trkMax].value += 1]]></eval>
</thing>
Edit:
If you're not copying/pasting this into the .user file and trying to build it piece by piece, it is important to know that
DiceSize.? & Helper.HitDieShow
won't work, you have to type the following into the editor:
DiceSize.? & Helper.HitDieShow
This happens because the editor has to save what you type as xml and certain characters like the & are saved as an XML sequence.
Last edited by dungeonguru; August 3rd, 2018 at 03:19 AM.
Reason: Clarify
|