This commit is contained in:
WBHarry 2025-11-10 14:02:44 +01:00 committed by GitHub
parent 321b7c2da3
commit 66961d7fea
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 20 additions and 10 deletions

View file

@ -166,11 +166,16 @@ export const healingTypes = {
export const defeatedConditions = () => {
const defeated = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Automation).defeated;
return Object.values(defeatedConditionChoices).map(x => ({
...x,
img: defeated[`${x.id}Icon`],
description: `DAGGERHEART.CONFIG.Condition.${x.id}.description`
}));
return Object.keys(defeatedConditionChoices).reduce((acc, key) => {
const choice = defeatedConditionChoices[key];
acc[key] = {
...choice,
img: defeated[`${choice.id}Icon`],
description: `DAGGERHEART.CONFIG.Condition.${choice.id}.description`
};
return acc;
}, {});
};
const defeatedConditionChoices = {