Added aseDie.rerollResult method to specifically reroll a specific result die in a grouping

This commit is contained in:
WBHarry 2026-07-15 14:58:02 +02:00
parent 1274639ba8
commit 221b84726d
7 changed files with 25 additions and 5 deletions

View file

@ -35,8 +35,7 @@ export class ChatDamageData extends foundry.abstract.DataModel {
async rerollDamageDie(damageType, dice, resultIndex) {
const reroll = this.types[damageType].roll;
const rerollDice = reroll.dice[dice];
const diceResult = rerollDice.results[resultIndex];
await rerollDice.reroll(`/r1=${diceResult.result}`);
await rerollDice.rerollResult(resultIndex);
await reroll._evaluate();
const rerolledResult = rerollDice.results[rerollDice.results.length - 1];