mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-03-07 14:36:13 +01:00
Fixed effect stacking
This commit is contained in:
parent
79057b0718
commit
617f1d64c1
7 changed files with 37 additions and 28 deletions
|
|
@ -95,7 +95,10 @@ export default class DhEffectsDisplay extends HandlebarsApplicationMixin(Applica
|
|||
|
||||
if (!effect.system.stacking?.enabled) return;
|
||||
|
||||
const newValue = Math.min(effect.system.stacking.value + 1, effect.system.stacking.max);
|
||||
const incrementedValue = effect.system.stacking.value + 1;
|
||||
const newValue = effect.system.stacking.max
|
||||
? Math.min(incrementedValue, effect.system.stacking.max)
|
||||
: incrementedValue;
|
||||
await effect.update({ 'system.stacking.value': newValue });
|
||||
this.render();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue