Rollable damages + protection

This commit is contained in:
2022-01-16 22:06:49 +01:00
parent 69b6fbca6b
commit 831b192691
8 changed files with 197 additions and 304 deletions

View File

@ -182,6 +182,7 @@ export class BoLActorSheet extends ActorSheet {
const dataset = element.dataset;
const actorData = this.getData();
const rollType = dataset.rollType;
const li = $(event.currentTarget).closest(".item");
switch(rollType) {
case "attribute" :
BoLRoll.attributeCheck(this.actor, actorData, dataset, event);
@ -192,6 +193,12 @@ export class BoLActorSheet extends ActorSheet {
case "weapon":
BoLRoll.weaponCheck(this.actor, actorData, dataset, event);
break;
case "protection":
this.actor.rollProtection(li.data("item-id"))
break;
case "damage":
this.actor.rollWeaponDamage(li.data("item-id"))
break;
default : break;
}
}