Open p4535992 opened 10 months ago
Thanks for reporting!
Are there parts that work and parts that do not work? Which aspects are currently not working?
From what I've noticed as a user, the color on the encumbrance bar and numerical values doesn't update in real time (see the video below), you need to refresh the page.
This is very helpful, thank you! With this in mind, I will look over the make-up of the module and determine what actions are needed.
I'll have to come back to this later, in light of the dnd5e 3.0.0 situation.
dnd5e 2.4.1; tidy 1.0.0; variant encumbrance 0.15.0
Adding to previous user testing post: weight on items does not update on equip/unequip if any of the "equipped/proficient multiplier" settings are enabled (example: 50lb unequipped, 25lb equipped). It just ignores updating values in the sheet. Values in VE debug come back right though, so that's probably on the sheet side.
@p4535992 I do have a recommendation for this now. 2 Steps for Tidy integration:
tidy5e-sheet.renderActorSheet
hook for injecting content
When injecting into Tidy, use the tidy5e-sheet.renderActorSheet
hook instead of the renderActorSheet
hooks. This hook fires every time a change occurs with Tidy sheets. The renderActorSheet
hooks only fire when there a full / forced render. This has to do with Tidy using Svelte and how Svelte takes over reactivity after that first full render of the sheet.Hooks.on(`tidy5e-sheet.renderActorSheet`, (app, element, data, forced) => {
const html = $(element);
// Inject something here.
});
data-tidy-render-scheme="handlebars"
on the topmost HTML element(s) to be injected, or wrap your markup with something like <div style="display: contents;" data-tidy-render-scheme="handlebars"></div>
. data-tidy-render-scheme="handlebars"
tells Tidy to remove the HTML during its next render. This, combined with injecting using the hook I mentioned above, will cause the content to refresh as expected.I fired up Variant encumbrance today in dnd5e 3.2, and I now see the weight updating. Is it working for everyone else? If so, are there any remaining Tidy-related issues to be resolved?
I have updated my module to keep track of the 3.2.0 breaking changes in the Dnd5e system (the latest version at a minimum of 3.2.0 in the manifest).
There remains the visual bar problem which is “not easy” to solve (at least for me), I am still deciding whether to abandon the sheet customization ui altogether and just update the “encumbrance” on the actor and let the sheet work with its own rules....
I have opened a commission about this for anyone interested on the league discord server.
The encumbrance bar do not play nicely with your sheet let me know possibly if you need any APIs for better integration.
Here the module reference: https://github.com/p4535992/foundryvtt-variant-encumbrance-dnd5e