ElfFriend-DnD / foundryvtt-compactBeyond5eSheet

A character sheet built with the intention of mimicing the dndbeyond character sheet layout and UX
MIT License
14 stars 16 forks source link

Set hp.temp to data-dtype Number to fix string concatenation bug #52

Closed CeaneC closed 3 years ago

CeaneC commented 3 years ago

https://github.com/ElfFriend-DnD/foundryvtt-compactBeyond5eSheet/blob/4d7957cd8368f52365d8679d788ff6acbdf04901/src/templates/parts/sheet-header.hbs#L111

Temp HP isn't typed at the moment, so the value is stored as a string when using this character sheet. This leads to problems when using modules like Health Estimate, which (depending on settings) try to add Temp HP and Base HP together.

E.g. a character with 1 temp HP and 16/32 HP would show as having 116/32 HP.

image

This happens on Foundry 0.7.10, using version 0.15.0 of Compact D&D Beyond Sheet.

akrigline commented 3 years ago

Nice catch! Are you willing to open a pull request with this fix for me?