mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-04-21 23:13:39 +02:00
Fixes (#1774)
This commit is contained in:
parent
331f1ebf75
commit
7057504a9e
6 changed files with 46 additions and 16 deletions
|
|
@ -43,9 +43,10 @@ export default class DualityDie extends foundry.dice.terms.Die {
|
|||
options: { appearance: {} }
|
||||
};
|
||||
|
||||
const preset = await getDiceSoNicePreset(diceSoNice[key], faces);
|
||||
diceSoNiceRoll.dice[0].options.appearance = preset.appearance;
|
||||
diceSoNiceRoll.dice[0].options.modelFile = preset.modelFile;
|
||||
const diceAppearance = await this.getDiceSoNiceAppearance(options.liveRoll.roll);
|
||||
diceSoNiceRoll.dice[0].options.appearance = diceAppearance.appearance;
|
||||
diceSoNiceRoll.dice[0].options.modelFile = diceAppearance.modelFile;
|
||||
diceSoNiceRoll.dice[0].results = diceSoNiceRoll.dice[0].results.filter(x => x.active);
|
||||
|
||||
await game.dice3d.showForRoll(diceSoNiceRoll, game.user, true);
|
||||
} else {
|
||||
|
|
@ -59,4 +60,11 @@ export default class DualityDie extends foundry.dice.terms.Die {
|
|||
this.#updateResources(oldDuality, newDuality, options.liveRoll.actor);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Overridden by extending classes HopeDie and FearDie
|
||||
*/
|
||||
async getDiceSoNiceAppearance() {
|
||||
return {};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue