Skip to content
Merged
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Changed format of added damage
  • Loading branch information
Wires77 committed Jul 21, 2021
commit a60c59e269875c87fa609ac1ab23bbec3c34e0e6
9 changes: 3 additions & 6 deletions src/Modules/CalcOffence.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1859,19 +1859,16 @@ function calcs.offence(env, actor, activeSkill)
breakdown[damageType] = { damageTypes = { } }
if baseMin ~= 0 and baseMax ~= 0 then
t_insert(breakdown[damageType], "Base damage:")
local plus = false
local plus = ""
if (source[damageTypeMin] or 0) ~= 0 or (source[damageTypeMax] or 0) ~= 0 then
t_insert(breakdown[damageType], s_format("%d to %d ^8(base damage from %s)", source[damageTypeMin], source[damageTypeMax], source.type and "weapon" or "skill"))
if baseMultiplier ~= 1 then
t_insert(breakdown[damageType], s_format("x %.2f ^8(base damage multiplier)", baseMultiplier))
end
plus = true
plus = "+ "
end
if addedMin ~= 0 or addedMax ~= 0 then
if plus then
t_insert(breakdown[damageType], "+")
end
t_insert(breakdown[damageType], s_format("%d to %d ^8(added damage)", addedMin, addedMax))
t_insert(breakdown[damageType], s_format("%s%d to %d ^8(added damage)", plus, addedMin, addedMax))
if damageEffectiveness ~= 1 then
t_insert(breakdown[damageType], s_format("x %.2f ^8(damage effectiveness)", damageEffectiveness))
end
Expand Down