[Feature] Damage-Reroll (#753)

* Added rerolls for damage dice in chat

* Fixed multiple dice

* Added reroll icon

* Fixed new style of dialog
This commit is contained in:
WBHarry 2025-08-10 01:32:12 +02:00 committed by GitHub
parent 2aaab73699
commit 300719c116
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
28 changed files with 1094 additions and 167 deletions

View file

@ -644,7 +644,7 @@ export default class DhpActor extends Actor {
);
break;
case 'armor':
if(this.system.armor?.system?.marks) {
if (this.system.armor?.system?.marks) {
updates.armor.resources['system.marks.value'] = Math.max(
Math.min(this.system.armor.system.marks.value + r.value, this.system.armorScore),
0
@ -652,9 +652,12 @@ export default class DhpActor extends Actor {
}
break;
default:
if(this.system.resources?.[r.key]) {
if (this.system.resources?.[r.key]) {
updates.actor.resources[`system.resources.${r.key}.value`] = Math.max(
Math.min(this.system.resources[r.key].value + r.value, this.system.resources[r.key].max),
Math.min(
this.system.resources[r.key].value + r.value,
this.system.resources[r.key].max
),
0
);
}