Skip to content

Commit d22114b

Browse files
LocalIdentityLocalIdentity
andauthored
Fix Fortification config not limiting to max possible Fortify (#9303)
The config was setting a override for the number of Fortification stacks but this was not get limited by the maximum potential fortification stacks So incrementing the number above your max was still affecting stuff like eHP or per fortification stats Co-authored-by: LocalIdentity <[email protected]>
1 parent 1097e0f commit d22114b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Modules/CalcPerform.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -616,7 +616,7 @@ local function doActorMisc(env, actor)
616616
if modDB:Flag(nil, "Fortified") or modDB:Sum("BASE", nil, "Multiplier:Fortification") > 0 then
617617
local maxStacks = modDB:Override(nil, "MaximumFortification") or modDB:Sum("BASE", skillCfg, "MaximumFortification")
618618
local minStacks = m_min(modDB:Flag(nil, "Condition:HaveMaxFortification") and maxStacks or modDB:Sum("BASE", nil, "MinimumFortification"), maxStacks)
619-
local stacks = modDB:Override(nil, "FortificationStacks") or (alliedFortify > 0 and alliedFortify) or (minStacks > 0 and minStacks) or maxStacks
619+
local stacks = m_min(modDB:Override(nil, "FortificationStacks") or (alliedFortify > 0 and alliedFortify) or (minStacks > 0 and minStacks) or maxStacks, maxStacks)
620620
output.FortificationStacks = stacks
621621
output.FortificationStacksOver20 = m_min(m_max(0, stacks - 20), maxStacks - 20)
622622
if not modDB:Flag(nil,"Condition:NoFortificationMitigation") then

0 commit comments

Comments
 (0)