asacolips-projects / dungeonworld

Create campaigns in Foundry VTT using the Dungeon World RPG!
MIT License
8 stars 4 forks source link

XP customization not working #84

Closed asacolips closed 7 months ago

asacolips commented 2 years ago

In GitLab by @Asacolips on Apr 25, 2022, 14:35

Notes

From Rant in the Foundry Discord:

Having a weird issue in the Dungeon World system with level-up XP. I'm currently playing Homebrew World but wanted to change the amount of XP needed for an advancement. In HBW, the default is 5 per level. This works just fine if XP Formula (in System Settings) is set to 5. But any time I try to change it to something that's not just a constant, it disregards whatever I've put there and treats it as the default Dungeon World value (what amounts to @attributes.level.value + 7. Basically I want it to be @attributes.level.value + 4 but that doesn't work. I've tried other variations ((@attributes.level.value + 4) or 4 + @attributes.value.level) but it disregards those. Referencing that value (@attributes.level.value) with rolls works fine, it's just the XP formula part.

One thing I did notice is that if I have that formula in there, whenever I click the + or - XP button the char sheet, a console warning pops up about Roll#evaluate becoming asynchronous. That doesn't happen if the field is just 5 (HBW default). Not sure if that has anything to do with it though.

Acceptance Criteria

asacolips commented 2 years ago

In GitLab by @Asacolips on Apr 28, 2022, 20:16

marked the checklist item Resolve issue with custom XP formulas as completed

asacolips commented 2 years ago

In GitLab by @Asacolips on Apr 28, 2022, 20:18

marked the checklist item Resolve Foundry v9 warnings as completed

asacolips commented 2 years ago

In GitLab by @Asacolips on Apr 28, 2022, 20:24

This has been merged and will be included in the next release of the system.

asacolips commented 2 years ago

In GitLab by @Asacolips on May 29, 2022, 22:18

mentioned in commit 51d5c052a77ecf2c00df98833da3629b5501b760