From 63e7f72753fdea80a677b11178210c883a6bf8f3 Mon Sep 17 00:00:00 2001 From: sladecraven Date: Sun, 16 Jan 2022 12:24:57 +0100 Subject: [PATCH] Fix mod --- modules/pegasus-actor.js | 10 +++++----- system.json | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/modules/pegasus-actor.js b/modules/pegasus-actor.js index 90bb11f..adfb7fb 100644 --- a/modules/pegasus-actor.js +++ b/modules/pegasus-actor.js @@ -570,24 +570,24 @@ export class PegasusActor extends Actor { /* -------------------------------------------- */ computeNRGHealth() { - let phyDiceValue = PegasusUtility.getDiceValue(this.data.data.statistics.phy.value); + let phyDiceValue = PegasusUtility.getDiceValue(this.data.data.statistics.phy.value) + this.data.data.statistics.phy.mod; if (phyDiceValue != this.data.data.secondary.health.max) { this.update({ 'data.secondary.health.max': phyDiceValue, 'data.secondary.health.value': phyDiceValue }) } - let mndDiceValue = PegasusUtility.getDiceValue(this.data.data.statistics.mnd.value); + let mndDiceValue = PegasusUtility.getDiceValue(this.data.data.statistics.mnd.value) + this.data.data.statistics.mnd.mod; if (mndDiceValue != this.data.data.secondary.delirium.max) { this.update({ 'data.secondary.delirium.max': mndDiceValue, 'data.secondary.delirium.value': mndDiceValue }) } - let stlDiceValue = PegasusUtility.getDiceValue(this.data.data.statistics.stl.value); + let stlDiceValue = PegasusUtility.getDiceValue(this.data.data.statistics.stl.value) +this.data.data.statistics.stl.mod; if (stlDiceValue != this.data.data.secondary.stealthhealth.max) { this.update({ 'data.secondary.stealthhealth.max': stlDiceValue, 'data.secondary.stealthhealth.value': stlDiceValue }) } - let socDiceValue = PegasusUtility.getDiceValue(this.data.data.statistics.soc.value); + let socDiceValue = PegasusUtility.getDiceValue(this.data.data.statistics.soc.value) + this.data.data.statistics.soc.mod; if (socDiceValue != this.data.data.secondary.socialhealth.max) { this.update({ 'data.secondary.socialhealth.max': socDiceValue, 'data.secondary.socialhealth.value': socDiceValue }) } - let nrgValue = PegasusUtility.getDiceValue(this.data.data.statistics.foc.value); + let nrgValue = PegasusUtility.getDiceValue(this.data.data.statistics.foc.value) + + this.data.data.statistics.foc.mod; if (nrgValue != this.data.data.nrg.max) { this.update({ 'data.nrg.max': nrgValue, 'data.nrg.value': nrgValue }) } diff --git a/system.json b/system.json index e76699d..fb2d25c 100644 --- a/system.json +++ b/system.json @@ -163,6 +163,6 @@ "templateVersion": 57, "title": "Pegasus RPG", "url": "https://www.uberwald.me/data/files/fvtt-pegasus-rpg", - "version": "0.1.2", + "version": "0.1.3", "background" : "./images/ui/pegasus_welcome_page.webp" }