From 61055eebe59de6b98b88142b89ed2b94c1299301 Mon Sep 17 00:00:00 2001 From: David Hewson Date: Fri, 21 Aug 2020 10:19:02 +0100 Subject: [PATCH] Fix: ground work should take into account waste-not reducing cost --- app/js/ffxivcraftmodel.js | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/app/js/ffxivcraftmodel.js b/app/js/ffxivcraftmodel.js index 9fabc19fc..1f5259ec0 100644 --- a/app/js/ffxivcraftmodel.js +++ b/app/js/ffxivcraftmodel.js @@ -267,6 +267,17 @@ function ApplyModifiers(s, action, condition) { } successProbability = Math.min(successProbability, 1); + // Effects modifying durability cost + var durabilityCost = action.durabilityCost; + if ((AllActions.wasteNot.shortName in s.effects.countDowns) || (AllActions.wasteNot2.shortName in s.effects.countDowns)) { + if (isActionEq(action, AllActions.prudentTouch)) { + bQualityGain = 0; + } + else { + durabilityCost *= 0.5; + } + } + // Effects modifying progress increase multiplier var progressIncreaseMultiplier = 1; @@ -291,7 +302,7 @@ function ApplyModifiers(s, action, condition) { cpCost = 0; } } - if (isActionEq(action, AllActions.groundwork) && s.durabilityState < 20) { + if (isActionEq(action, AllActions.groundwork) && s.durabilityState < durabilityCost) { progressIncreaseMultiplier *= 0.5; } @@ -360,17 +371,6 @@ function ApplyModifiers(s, action, condition) { } } - // Effects modifying durability cost - var durabilityCost = action.durabilityCost; - if ((AllActions.wasteNot.shortName in s.effects.countDowns) || (AllActions.wasteNot2.shortName in s.effects.countDowns)) { - if (isActionEq(action, AllActions.prudentTouch)) { - bQualityGain = 0; - } - else { - durabilityCost *= 0.5; - } - } - return { craftsmanship: craftsmanship, control: control,