javalent / fantasy-statblocks

Create Dungeons and Dragons style statblocks for Obsidian.md
MIT License
341 stars 71 forks source link

hit_dice formula returns addition result when given subtraction #350

Closed rpie3 closed 4 months ago

rpie3 commented 5 months ago

Check for existing bug reports before submitting.

Expected Behavior

Default rendered hp for hit_dice using subtraction modifiers should show the roll result with the modifier subtracted.

Current behaviour

Default rendered hp for hit_dice using subtraction modifiers are showing the roll result with the modifier added.

Reproduction

I am using the fields:

hp: 7
hit_dice: 3d6 - 3

and seeing rendered output is 13. I have played around with other subtraction formulae and they all seem to be adding rather than subtracting as well. Another example:

hit_dice: 1d20 - 5

Renders output 15.

Which Operating Systems are you using?

Obsidian Version Check

1.5.3

Plugin Version

3.19.0

Confirmation

Possible solution

No response