Skip to content
This repository was archived by the owner on Oct 21, 2025. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions src/Modules/CalcOffence.lua
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ end

local function calcGainedDamage(activeSkill, output, cfg, damageType)
local gainTable = activeSkill.gainTable

local gainedMin, gainedMax = 0, 0
for _, otherType in ipairs(dmgTypeList) do
local baseMin = m_floor(output[otherType.."MinBase"])
Expand All @@ -100,7 +100,7 @@ local function calcGainedDamage(activeSkill, output, cfg, damageType)
gainedMax = gainedMax + (baseMax + convertedMax) * gainMult
end
end

return gainedMin, gainedMax
end

Expand Down Expand Up @@ -1895,7 +1895,7 @@ function calcs.offence(env, actor, activeSkill)
activeSkill.conversionTable[damageType][fromType] = data.base
end
for toType, amount in pairs(data.conv) do
activeSkill.conversionTable[damageType][toType] =
activeSkill.conversionTable[damageType][toType] =
(activeSkill.conversionTable[damageType][toType] or 0) + amount
end
end
Expand All @@ -1904,9 +1904,13 @@ function calcs.offence(env, actor, activeSkill)
activeSkill.gainTable[damageType] = {}
for _, toType in ipairs(dmgTypeList) do
local globalGain = m_max(skillModList:Sum("BASE", skillCfg,
"DamageAs"..toType,
"DamageGainAs"..toType,
damageType.."DamageAs"..toType,
damageType.."DamageGainAs"..toType,
isElemental[damageType] and "ElementalDamageAs"..toType or nil,
isElemental[damageType] and "ElementalDamageGainAs"..toType or nil,
damageType ~= "Chaos" and "NonChaosDamageAs"..toType or nil,
damageType ~= "Chaos" and "NonChaosDamageGainAs"..toType or nil), 0)
local skillGain = m_max(skillModList:Sum("BASE", skillCfg,
"SkillDamageGainAs"..toType,
Expand Down
Loading