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
22 changes: 22 additions & 0 deletions spec/System/TestItemMods_spec.lua
Original file line number Diff line number Diff line change
Expand Up @@ -220,4 +220,26 @@ describe("TetsItemMods", function()
assert.are_not.equals(120, build.calcsTab.mainOutput.Armour)
runCallback("OnFrame")
end)

it("all damage can contribute", function()
build.itemsTab:CreateDisplayItemFromRaw([[
Rarity: UNIQUE
Tidebreaker
Pointed Maul
League: Dawn of the Hunt
Quality: 20
LevelReq: 45
Implicits: 0
{range:0.5}(120-150)% increased Physical Damage
{range:0.5}+(2-3) to Level of all Melee Skills
{range:0.5}+(20-30) to Intelligence
{range:0.5}Causes (150-200)% increased Stun Buildup
All Damage from Hits with this Weapon Contributes to Chill Magnitude
]])
build.itemsTab:AddDisplayItem()
runCallback("OnFrame")
build.skillsTab:PasteSocketGroup("Leap Slam 20/0 1")
runCallback("OnFrame")
assert.True(build.calcsTab.calcsOutput.ChillEffectMod ~= nil)
end)
end)
20 changes: 8 additions & 12 deletions src/Data/ModCache.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3449,14 +3449,12 @@ c["Aggravating any Bleeding with this Weapon also Aggravates all Ignites on the
c["Aggravating any Bleeding with this Weapon also Aggravates all Ignites on the target 40% chance to Aggravate Bleeding on Hit"]={nil,"Aggravating any Bleeding with this Weapon also Aggravates all Ignites on the target 40% chance to Aggravate Bleeding on Hit "}
c["All Attacks count as Empowered Attacks"]={nil,"All Attacks count as Empowered Attacks "}
c["All Attacks count as Empowered Attacks Cannot use Warcries"]={nil,"All Attacks count as Empowered Attacks Cannot use Warcries "}
c["All Damage from Hits Contributes to Chill Magnitude"]={{[1]={flags=0,keywordFlags=0,name="PhysicalCanChill",type="FLAG",value=true},[2]={flags=0,keywordFlags=0,name="FireCanChill",type="FLAG",value=true},[3]={flags=0,keywordFlags=0,name="LightningCanChill",type="FLAG",value=true},[4]={flags=0,keywordFlags=0,name="ChaosCanChill",type="FLAG",value=true}},nil}
c["All Damage from Hits Contributes to Poison Magnitude"]={{[1]={flags=0,keywordFlags=0,name="FireCanPoison",type="FLAG",value=true},[2]={flags=0,keywordFlags=0,name="ColdCanPoison",type="FLAG",value=true},[3]={flags=0,keywordFlags=0,name="LightningCanPoison",type="FLAG",value=true}},nil}
c["All Damage from Hits Contributes to Chill Magnitude"]={{[1]={flags=0,keywordFlags=0,name="CanChill",type="FLAG",value=true}},nil}
c["All Damage from Hits Contributes to Poison Magnitude"]={{[1]={flags=0,keywordFlags=0,name="CanPoison",type="FLAG",value=true}},nil}
c["All Damage from Hits Contributes to Shock Chance"]={{[1]={flags=0,keywordFlags=0,name="PhysicalCanShock",type="FLAG",value=true},[2]={flags=0,keywordFlags=0,name="FireCanShock",type="FLAG",value=true},[3]={flags=0,keywordFlags=0,name="ColdCanShock",type="FLAG",value=true},[4]={flags=0,keywordFlags=0,name="ChaosCanShock",type="FLAG",value=true}},nil}
c["All Damage from Hits against Bleeding targets Contributes to Chill Magnitude"]={nil,"All Damage from Hits against Bleeding targets Contributes to Chill Magnitude "}
c["All Damage from Hits against Bleeding targets Contributes to Chill Magnitude 20% chance to inflict Bleeding on Hit"]={nil,"All Damage from Hits against Bleeding targets Contributes to Chill Magnitude 20% chance to inflict Bleeding on Hit "}
c["All Damage from Hits against Poisoned targets Contributes to Chill Magnitude"]={nil,"All Damage from Hits against Poisoned targets Contributes to Chill Magnitude "}
c["All Damage from Hits against Poisoned targets Contributes to Chill Magnitude 25% increased Magnitude of Poison you inflict"]={nil,"All Damage from Hits against Poisoned targets Contributes to Chill Magnitude 25% increased Magnitude of Poison you inflict "}
c["All Damage from Hits with this Weapon Contributes to Chill Magnitude"]={nil,"All Damage from Hits with this Weapon Contributes to Chill Magnitude "}
c["All Damage from Hits against Bleeding targets Contributes to Chill Magnitude"]={{[1]={[1]={actor="enemy",type="ActorCondition",var="Bleeding"},flags=0,keywordFlags=0,name="CanChill",type="FLAG",value=true}},nil}
c["All Damage from Hits against Poisoned targets Contributes to Chill Magnitude"]={{[1]={[1]={actor="enemy",type="ActorCondition",var="Poisoned"},flags=0,keywordFlags=0,name="CanChill",type="FLAG",value=true}},nil}
c["All Damage from Hits with this Weapon Contributes to Chill Magnitude"]={{[1]={[1]={type="Condition",var="{Hand}Attack"},[2]={skillType=1,type="SkillType"},flags=0,keywordFlags=0,name="CanChill",type="FLAG",value=true}},nil}
c["All Damage from Hits with this Weapon Contributes to Freeze Buildup"]={{[1]={[1]={type="Condition",var="{Hand}Attack"},flags=0,keywordFlags=0,name="CanFreeze",type="FLAG",value=true}},nil}
c["All Damage from Hits with this Weapon Contributes to Pin Buildup"]={{[1]={[1]={type="Condition",var="{Hand}Attack"},flags=0,keywordFlags=0,name="CanPin",type="FLAG",value=true}},nil}
c["All Damage from you and Allies in your Presence"]={nil,"All Damage from you and "}
Expand Down Expand Up @@ -4583,8 +4581,7 @@ c["Charms applied to you have 25% increased Effect"]={{[1]={[1]={actor="player",
c["Charms gain 0.15 charges per Second"]={{[1]={flags=0,keywordFlags=0,name="CharmChargesGenerated",type="BASE",value=0.15}},nil}
c["Charms gain 0.5 charges per Second"]={{[1]={flags=0,keywordFlags=0,name="CharmChargesGenerated",type="BASE",value=0.5}},nil}
c["Charms use no Charges"]={{[1]={flags=0,keywordFlags=0,name="CharmsUseNoCharges",type="FLAG",value=true}},nil}
c["Cold Damage from Hits Contributes to Flammability and Ignite Magnitudes instead of Chill Magnitude or Freeze Buildup"]={nil,"Cold Damage from Hits Contributes to Flammability and Ignite Magnitudes instead of Chill Magnitude or Freeze Buildup "}
c["Cold Damage from Hits Contributes to Flammability and Ignite Magnitudes instead of Chill Magnitude or Freeze Buildup Lightning Damage from Hits Contributes to Freeze Buildup instead of Shock Chance"]={nil,"Cold Damage from Hits Contributes to Flammability and Ignite Magnitudes instead of Chill Magnitude or Freeze Buildup Lightning Damage from Hits Contributes to Freeze Buildup instead of Shock Chance "}
c["Cold Damage from Hits Contributes to Flammability and Ignite Magnitudes instead of Chill Magnitude or Freeze Buildup"]={{[1]={flags=0,keywordFlags=0,name="ColdCanIgnite",type="FLAG",value=true},[2]={flags=0,keywordFlags=0,name="ColdCannotChill",type="FLAG",value=true},[3]={flags=0,keywordFlags=0,name="ColdCannotFreeze",type="FLAG",value=true}},nil}
c["Cold Resistance is unaffected by Area Penalties"]={nil,"Cold Resistance is unaffected by Area Penalties "}
c["Cold Resistance is unaffected by Area Penalties Fire Resistance is unaffected by Area Penalties"]={nil,"Cold Resistance is unaffected by Area Penalties Fire Resistance is unaffected by Area Penalties "}
c["Combo count loss occurs 20% slower"]={nil,"Combo count loss occurs 20% slower "}
Expand Down Expand Up @@ -4893,8 +4890,7 @@ c["Excess Life Recovery from Leech is applied to Energy Shield"]={nil,"Excess Li
c["Excess Life Recovery from Regeneration is applied to Energy Shield"]={{[1]={[1]={type="Condition",var="FullLife"},flags=0,keywordFlags=0,name="ZealotsOath",type="FLAG",value=true}},nil}
c["Exposure you inflict lowers Resistances by an additional 5%"]={{[1]={flags=0,keywordFlags=0,name="ExtraExposure",type="BASE",value=-5}},nil}
c["Final Repeat of Spells has 30% increased Area of Effect"]={{[1]={[1]={neg=true,type="Condition",var="CastOnFrostbolt"},[2]={type="Condition",varList={[1]="averageRepeat",[2]="alwaysFinalRepeat"}},flags=2,keywordFlags=0,name="RepeatFinalAreaOfEffect",type="INC",value=30}},nil}
c["Fire Damage from Hits Contributes to Shock Chance instead of Flammability and Ignite Magnitudes"]={nil,"Fire Damage from Hits Contributes to Shock Chance instead of Flammability and Ignite Magnitudes "}
c["Fire Damage from Hits Contributes to Shock Chance instead of Flammability and Ignite Magnitudes Cold Damage from Hits Contributes to Flammability and Ignite Magnitudes instead of Chill Magnitude or Freeze Buildup"]={nil,"Fire Damage from Hits Contributes to Shock Chance instead of Flammability and Ignite Magnitudes Cold Damage from Hits Contributes to Flammability and Ignite Magnitudes instead of Chill Magnitude or Freeze Buildup "}
c["Fire Damage from Hits Contributes to Shock Chance instead of Flammability and Ignite Magnitudes"]={{[1]={flags=0,keywordFlags=0,name="FireCanShock",type="FLAG",value=true},[2]={flags=0,keywordFlags=0,name="FireCannotIgnite",type="FLAG",value=true}},nil}
c["Fire Resistance is unaffected by Area Penalties"]={nil,"Fire Resistance is unaffected by Area Penalties "}
c["Fire Resistance is unaffected by Area Penalties Lightning Resistance is unaffected by Area Penalties"]={nil,"Fire Resistance is unaffected by Area Penalties Lightning Resistance is unaffected by Area Penalties "}
c["Fire Spells Convert 100% of Fire Damage to Chaos Damage"]={{[1]={[1]={skillType=2,type="SkillType"},[2]={skillType=28,type="SkillType"},flags=0,keywordFlags=0,name="FireDamageConvertToChaos",type="BASE",value="100"}},nil}
Expand Down Expand Up @@ -5471,7 +5467,7 @@ c["Life Recovery from your Flasks also applies to your Companions"]={nil,"Life R
c["Life Regeneration is applied to Energy Shield instead"]={{[1]={flags=0,keywordFlags=0,name="ZealotsOath",type="FLAG",value=true}},nil}
c["Life and Mana Flasks can be equipped in either slot"]={nil,"Life and Mana Flasks can be equipped in either slot "}
c["Life that would be lost by taking Damage is instead Reserved"]={{[1]={flags=0,keywordFlags=0,name="DamageInsteadReservesLife",type="FLAG",value=true}},nil}
c["Lightning Damage from Hits Contributes to Freeze Buildup instead of Shock Chance"]={nil,"Lightning Damage from Hits Contributes to Freeze Buildup instead of Shock Chance "}
c["Lightning Damage from Hits Contributes to Freeze Buildup instead of Shock Chance"]={{[1]={flags=0,keywordFlags=0,name="LightningCanFreeze",type="FLAG",value=true},[2]={flags=0,keywordFlags=0,name="LightningCannotShock",type="FLAG",value=true}},nil}
c["Lightning Damage of Enemies Hitting you is Unlucky"]={nil,"Lightning Damage of Enemies Hitting you is Unlucky "}
c["Lightning Damage of Enemies Hitting you is Unlucky during effect"]={nil,"Lightning Damage of Enemies Hitting you is Unlucky during effect "}
c["Lightning Resistance does not affect Lightning damage taken"]={{[1]={flags=0,keywordFlags=0,name="SelfIgnoreLightningResistance",type="FLAG",value=true}},nil}
Expand Down
72 changes: 24 additions & 48 deletions src/Modules/ModParser.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2942,48 +2942,39 @@ local specialModList = {
mod("EnemyShockChance", "BASE", 100) ,
mod("EnemyIgniteChance", "BASE", 100),
},
["all damage with hits can ignite"] = {
flag("PhysicalCanIgnite"),
flag("ColdCanIgnite"),
flag("LightningCanIgnite"),
flag("ChaosCanIgnite"),
},
["all damage can ignite"] = {
flag("PhysicalCanIgnite"),
flag("ColdCanIgnite"),
flag("LightningCanIgnite"),
flag("ChaosCanIgnite"),
},
["all damage with hits can chill"] = {
flag("PhysicalCanChill"),
flag("FireCanChill"),
flag("LightningCanChill"),
flag("ChaosCanChill"),
},
["all damage with hits can shock"] = {
-- Can..ailment applies to all damageTypes vs PhysicalCan..ailment, FireCan..ailment etc
["all damage ?w?i?t?h? ?h?i?t?s? can (%a+)"] = function(_, ailment) return {
flag("Can"..firstToUpper(ailment)),
} end,
["all damage from hits contributes to shock chance"] = {
flag("PhysicalCanShock"),
flag("FireCanShock"),
flag("ColdCanShock"),
flag("ChaosCanShock"),
},
["all damage from hits contributes to shock chance"] = {
flag("PhysicalCanShock"),
-- Three Dragons
["fire damage from hits contributes to shock chance instead of flammability and ignite magnitudes"] = {
flag("FireCanShock"),
flag("ColdCanShock"),
flag("ChaosCanShock"),
flag("FireCannotIgnite"),
},
["all damage from hits contributes to chill magnitude"] = {
flag("PhysicalCanChill"),
flag("FireCanChill"),
flag("LightningCanChill"),
flag("ChaosCanChill"),
["cold damage from hits contributes to flammability and ignite magnitudes instead of chill magnitude or freeze buildup"] = {
flag("ColdCanIgnite"),
flag("ColdCannotChill"),
flag("ColdCannotFreeze"),
},
["all damage can shock"] = {
flag("PhysicalCanShock"),
flag("FireCanShock"),
flag("ColdCanShock"),
flag("ChaosCanShock"),
["lightning damage from hits contributes to freeze buildup instead of shock chance"] = {
flag("LightningCanFreeze"),
flag("LightningCannotShock"),
},
["all damage from hits contributes to (%a+) magnitude"] = function(_, ailment) return {
flag("Can"..firstToUpper(ailment)),
} end,
["all damage from hits with this weapon contributes to (%a+) magnitude"] = function(_, ailment) return {
flag("Can"..firstToUpper(ailment), { type = "Condition", var = "{Hand}Attack" }, { type = "SkillType", skillType = SkillType.Attack }),
} end,
["all damage from hits against (%a+) targets contributes to (%a+) magnitude"] = function(_, ailment, ailment2) return {
flag("Can"..firstToUpper(ailment2), { type = "ActorCondition", actor = "enemy", var = firstToUpper(ailment) }),
} end,
["other aegis skills are disabled"] = {
flag("DisableSkill", { type = "SkillType", skillType = SkillType.Aegis }),
flag("EnableSkill", { type = "SkillName", skillId = "Primal Aegis" }),
Expand Down Expand Up @@ -3970,16 +3961,6 @@ local specialModList = {
["y?o?u?r? ?fire damage can poison"] = { flag("FireCanPoison") },
["y?o?u?r? ?cold damage can poison"] = { flag("ColdCanPoison") },
["y?o?u?r? ?lightning damage can poison"] = { flag("LightningCanPoison") },
["all damage from hits can poison"] = {
flag("FireCanPoison"),
flag("ColdCanPoison"),
flag("LightningCanPoison"),
},
["all damage can poison"] = {
flag("FireCanPoison"),
flag("ColdCanPoison"),
flag("LightningCanPoison"),
},
["all damage from hits with this weapon can poison"] = {
flag("FireCanPoison", { type = "Condition", var = "{Hand}Attack" }, { type = "SkillType", skillType = SkillType.Attack }),
flag("ColdCanPoison", { type = "Condition", var = "{Hand}Attack" }, { type = "SkillType", skillType = SkillType.Attack }),
Expand All @@ -4001,11 +3982,6 @@ local specialModList = {
flag("ColdCanPoison", { type = "SkillName", skillNameList = { "Freezing Pulse", "Eye of Winter" }, includeTransfigured = true }),
flag("LightningCanPoison", { type = "SkillName", skillNameList = { "Freezing Pulse", "Eye of Winter" }, includeTransfigured = true })
},
["all damage from hits contributes to poison magnitude"] = {
flag("FireCanPoison"),
flag("ColdCanPoison"),
flag("LightningCanPoison"),
},
["all damage from you and allies in your presence contributes to ignite chance and magnitude"] = {
mod("ExtraAura", "LIST", { mod = flag("ColdCanIgnite") }),
mod("ExtraAura", "LIST", { mod = flag("LightningCanIgnite") }),
Expand Down
Loading