From 70a29dafd9ffdc47f3db52f68a118ad54876a605 Mon Sep 17 00:00:00 2001 From: Dapoulp Date: Sun, 1 Jun 2025 22:40:14 +0200 Subject: [PATCH] Fix clients fear update --- module/applications/resources.mjs | 1 - module/applications/settings.mjs | 5 ++++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/module/applications/resources.mjs b/module/applications/resources.mjs index 535a1631..86f85178 100644 --- a/module/applications/resources.mjs +++ b/module/applications/resources.mjs @@ -105,6 +105,5 @@ export default class Resources extends HandlebarsApplicationMixin(ApplicationV2) if(!game.user.isGM) return; value = Math.max(0, Math.min(this.maxFear, value)); await game.settings.set(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.Resources.Fear, value); - await this.render(true); } } \ No newline at end of file diff --git a/module/applications/settings.mjs b/module/applications/settings.mjs index c86af3a7..4a885d17 100644 --- a/module/applications/settings.mjs +++ b/module/applications/settings.mjs @@ -179,7 +179,10 @@ export const registerDHSettings = () => { scope: 'world', config: false, type: Number, - default: 0 + default: 0, + onChange: () => { + if(ui.resources) ui.resources.render({force: true}); + } }); game.settings.register(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.Resources.MaxFear, {