Skip to content
Open
Show file tree
Hide file tree
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
430 changes: 428 additions & 2 deletions spec/System/TestTriggers_spec.lua

Large diffs are not rendered by default.

54 changes: 23 additions & 31 deletions src/Data/ModCache.lua

Large diffs are not rendered by default.

55 changes: 55 additions & 0 deletions src/Data/SkillStatMap.lua
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,61 @@ return function(mod, flag, skill)
["generic_ongoing_triggerer_is_invocation_skill"] = {
flag("Condition:InvocationSkill"),
},
-- Meta gem Energy
["energy_generated_+%"] = {
mod("EnergyGenerated", "INC", nil),
},
["generic_ongoing_trigger_triggers_at_maximum_energy"] = {
skill("triggersAtMaxEnergy", true),
},
["generic_ongoing_trigger_maximum_energy_is_total_of_socketed_skills"] = {
skill("maxEnergyFromSocketedSkills", true),
},
["generic_ongoing_trigger_maximum_energy"] = {
skill("maxEnergy", nil),
},
-- Applied by the hidden support to each skill socketed in the meta gem
["generic_ongoing_trigger_1_maximum_energy_per_Xms_total_cast_time"] = {
skill("energyPerCastTimeMs", nil),
},
["trigger_skills_refund_half_energy_spent_chance_%"] = {
mod("EnergyRefundChance", "BASE", nil),
},
["trigger_meta_gem_damage_+%_final"] = {
mod("Damage", "MORE", nil),
},
["cast_on_dodge_dodge_roll_distance_granted_+"] = {
mod("DodgeRollDistance", "BASE", nil, 0, 0, { type = "GlobalEffect", effectType = "Buff" }),
div = 10,
},
-- Energy that meta gems gain from this skill's hits
["active_skill_energy_generated_+%_final"] = {
mod("EnergyGeneratedFromSkill", "MORE", nil),
},
["cast_on_crit_gain_X_centienergy_per_monster_power_on_crit"] = {
skill("energyPerPowerOnCrit", nil),
div = 100,
},
["cast_on_dodge_roll_gain_X_centienergy_per_unit_travelled_while_dodge_rolling"] = {
skill("energyPerMetreDodgeRolling", nil),
div = 100,
},
["cast_fire_spell_on_hit_gain_X_centienergy_per_monster_power_on_hit"] = {
skill("energyPerPowerOnMeleeHit", nil),
div = 100,
},
["cast_lightning_spell_on_hit_gain_X_centienergy_per_monster_power_on_hit"] = {
skill("energyPerPowerOnMeleeHit", nil),
div = 100,
},
["cast_on_block_gain_X_centienergy_on_block"] = {
skill("energyOnBlock", nil),
div = 100,
},
["cast_on_using_charm_gain_X_centienergy_per_charm_charge_used_on_using_charm"] = {
skill("energyPerCharmCharge", nil),
div = 100,
},
["base_skill_cost_life_instead_of_mana_%"] = {
mod("HybridManaAndLifeCost_Life", "BASE", nil),
},
Expand Down
6 changes: 1 addition & 5 deletions src/Modules/BuildDisplayStats.lua
Original file line number Diff line number Diff line change
Expand Up @@ -82,21 +82,17 @@ local displayStats = {
{ stat = "IgniteDPS", label = "Ignite DPS", fmt = ".1f", compPercent = true, warnFunc = function(v) return v >= data.misc.DotDpsCap and "Ignite DPS exceeds in game limit" end },
{ stat = "IgniteDamage", label = "Total Damage per Ignite", fmt = ".1f", compPercent = true, flag = "showAverage" },
{ stat = "BurningGroundDPS", label = "Burning Ground DPS", fmt = ".1f", compPercent = true, warnFunc = function(v,o) return v >= data.misc.DotDpsCap and "Burning Ground DPS exceeds in game limit" end },
{ stat = "MirageBurningGroundDPS", label = "Mirage Burning Ground DPS", fmt = ".1f", compPercent = true, condFunc = function(v,o) return v ~= o.BurningGroundDPS end, warnFunc = function(v,o) return v >= data.misc.DotDpsCap and "Mirage Burning Ground DPS exceeds in game limit" end },
{ stat = "WithIgniteDPS", label = "Total DPS inc. Ignite", fmt = ".1f", compPercent = true, flag = "notAverage", condFunc = function(v,o) return v ~= o.TotalDPS and (o.TotalDot or 0) == 0 and (o.PoisonDPS or 0) == 0 and (o.ImpaleDPS or 0) == 0 and (o.BleedDPS or 0) == 0 end },
{ stat = "PoisonDPS", label = "Poison DPS", fmt = ".1f", compPercent = true, warnFunc = function(v) return v >= data.misc.DotDpsCap and "Poison DPS exceeds in game limit" end },
{ stat = "CausticGroundDPS", label = "Caustic Ground DPS", fmt = ".1f", compPercent = true, warnFunc = function(v,o) return v >= data.misc.DotDpsCap and "Caustic Ground DPS exceeds in game limit" end },
{ stat = "MirageCausticGroundDPS", label = "Mirage Caustic Ground DPS", fmt = ".1f", compPercent = true, condFunc = function(v,o) return v ~= o.CausticGroundDPS end, warnFunc = function(v,o) return v >= data.misc.DotDpsCap and "Mirage Caustic Ground DPS exceeds in game limit" end },
{ stat = "PoisonDamage", label = "Total Damage per Poison", fmt = ".1f", compPercent = true, flag = "showAverage" },
{ stat = "WithPoisonDPS", label = "Total DPS inc. Poison", fmt = ".1f", compPercent = true, flag = "notAverage", condFunc = function(v,o) return v ~= o.TotalDPS and (o.TotalDot or 0) == 0 and (o.IgniteDPS or 0) == 0 and (o.ImpaleDPS or 0) == 0 and (o.BleedDPS or 0) == 0 end },
{ stat = "DecayDPS", label = "Decay DPS", fmt = ".1f", compPercent = true },
{ stat = "TotalDotDPS", label = "Total DoT DPS", fmt = ".1f", compPercent = true, condFunc = function(v,o) return o.showTotalDotDPS or ( v ~= o.TotalDot and v ~= o.TotalPoisonDPS and v ~= o.CausticGroundDPS and v ~= (o.TotalIgniteDPS or o.IgniteDPS) and v ~= o.BurningGroundDPS and v ~= o.BleedDPS and v~= o.CorruptingBloodDPS and v ~= o.MirageCausticGroundDPS and v ~= o.MirageBurningGroundDPS) end, warnFunc = function(v) return v >= data.misc.DotDpsCap and "DoT DPS exceeds in game limit" end },
{ stat = "TotalDotDPS", label = "Total DoT DPS", fmt = ".1f", compPercent = true, condFunc = function(v,o) return o.showTotalDotDPS or ( v ~= o.TotalDot and v ~= o.TotalPoisonDPS and v ~= o.CausticGroundDPS and v ~= (o.TotalIgniteDPS or o.IgniteDPS) and v ~= o.BurningGroundDPS and v ~= o.BleedDPS and v~= o.CorruptingBloodDPS) end, warnFunc = function(v) return v >= data.misc.DotDpsCap and "DoT DPS exceeds in game limit" end },
{ stat = "ImpaleDPS", label = "Impale Damage", fmt = ".1f", compPercent = true, flag = "impale", flag = "showAverage" },
{ stat = "WithImpaleDPS", label = "Damage inc. Impale", fmt = ".1f", compPercent = true, flag = "impale", flag = "showAverage", condFunc = function(v,o) return v ~= o.TotalDPS and (o.TotalDot or 0) == 0 and (o.IgniteDPS or 0) == 0 and (o.PoisonDPS or 0) == 0 and (o.BleedDPS or 0) == 0 end },
{ stat = "ImpaleDPS", label = "Impale DPS", fmt = ".1f", compPercent = true, flag = "impale", flag = "notAverage" },
{ stat = "WithImpaleDPS", label = "Total DPS inc. Impale", fmt = ".1f", compPercent = true, flag = "impale", flag = "notAverage", condFunc = function(v,o) return v ~= o.TotalDPS and (o.TotalDot or 0) == 0 and (o.IgniteDPS or 0) == 0 and (o.PoisonDPS or 0) == 0 and (o.BleedDPS or 0) == 0 end },
{ stat = "MirageDPS", label = "Total Mirage DPS", fmt = ".1f", compPercent = true, flag = "mirageArcher", condFunc = function(v,o) return v > 0 end },
{ stat = "MirageDPS", label = "Total Wisp DPS", fmt = ".1f", compPercent = true, flag = "wisp", condFunc = function(v,o) return v > 0 end },
{ stat = "CullingDPS", label = "Culling DPS", fmt = ".1f", compPercent = true, condFunc = function(v,o) return (o.CullingDPS or 0) > 0 end },
{ stat = "ReservationDPS", label = "Reservation DPS", fmt = ".1f", compPercent = true, condFunc = function(v,o) return (o.ReservationDPS or 0) > 0 end },
{ stat = "CombinedDPS", label = "Combined DPS", fmt = ".1f", compPercent = true, flag = "notAverage", condFunc = function(v,o) return v ~= ((o.TotalDPS or 0) + (o.TotalDot or 0)) and v ~= o.WithImpaleDPS and ( o.showTotalDotDPS or ( v ~= o.WithPoisonDPS and v ~= o.WithIgniteDPS and v ~= o.WithBleedDPS ) ) end },
Expand Down
8 changes: 7 additions & 1 deletion src/Modules/CalcBase.lua
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,20 @@ return calcs
---@field BattleMageCryDuration number?
---@field BattlemageUpTimeRatio number?
---@field BleedDamage number?
---@field BlockChance number?
---@field ChaosHitAverage number?
---@field ChaosResist number?
---@field ColdHitAverage number?
---@field ColdResistOverCap number?
---@field ColdResistTotal number?
---@field CritChance number?
---@field CullMultiplier number?
---@field Dex number?
---@field EffectiveBlockChance number?
---@field EffectiveProjectileBlockChance number?
---@field EffectiveSpellBlockChance number?
---@field EffectiveSpellProjectileBlockChance number?
---@field EnergyPerSecond number?
---@field EnergyShieldLeechDuration number?
---@field EnergyShieldRecoupRecoveryAvg number?
---@field EnergyShieldRegenRecovery number?
Expand Down Expand Up @@ -63,6 +66,7 @@ return calcs
---@field ManaRecoupRecoveryAvg number?
---@field ManaRegenRecovery number?
---@field ManaUnreserved number?
---@field MaxEnergy number?
---@field PhysicalTakenDamage number?
---@field PhysicalTakenHit number?
---@field PoisonAvoidChance number?
Expand All @@ -73,10 +77,12 @@ return calcs
---@field SelfIgniteEffect number?
---@field SelfPoisonDuration number?
---@field SelfPoisonEffect number?
---@field SkillTriggerRate number?
---@field Str number?
---@field TotalVaalRejuvenationTotemLife number?
---@field TotemChaosResist number?
---@field TotemLife number?
---@field TriggerRateCap number?

---@class Breakdown
---@field MainHand Breakdown?
Expand Down Expand Up @@ -149,7 +155,6 @@ return calcs
---@field weapon2Flags number
---@field minion? Actor
---@field minionList? string[]
---@field mirage? table
---@field slotName? string
---@field skillPart? number
---@field skillPartName? string
Expand Down Expand Up @@ -220,6 +225,7 @@ return calcs
---@field weaponModList1? ModList
---@field sourceGemPropertyInfo? table<any, TabulatedMod[]>
---@field override? CalcOverride
---@field triggerSourceCache? table<string, CachedSkillData> Trigger source calculations shared by one calculator override's passes
---@field virtuousMoteSkillCount? table<string, number>
---@field skillsUsed? table<string, boolean>
---@field conditionsUsed? table<string, Mod[]>
Expand Down
Loading
Loading