Skip to content

Commit 238d451

Browse files
LocalIdentityLocalIdentity
andauthored
Fix Poison Conc of Bouncing with Runegraft of Refraction (#9195)
Rune graft of Refraction prevents the additional projectiles from adding chains Also fixes the Runegraft with Spectral Helix, Split Arrow of Splitting, Splitting Steel, and Ice Spear of Splitting Also realised I had the parsing incorrect fo the mod in ModParser so it was causing a crash on dev when trying to press alt Co-authored-by: LocalIdentity <[email protected]>
1 parent 36947a9 commit 238d451

File tree

5 files changed

+10
-9
lines changed

5 files changed

+10
-9
lines changed

src/Data/ModCache.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8457,7 +8457,7 @@ c["Fire Exposure you inflict applies an extra -5% to Fire Resistance"]={{[1]={fl
84578457
c["Fire Resistance is 75%"]={{[1]={flags=0,keywordFlags=0,name="FireResist",type="OVERRIDE",value=75}},nil}
84588458
c["Fire Skills have 20% chance to Poison on Hit"]={{[1]={flags=0,keywordFlags=32,name="PoisonChance",type="BASE",value=20}},nil}
84598459
c["Fire Skills have a 25% chance to apply Fire Exposure on Hit"]={{[1]={flags=0,keywordFlags=0,name="FireExposureChance",type="BASE",value=25}},nil}
8460-
c["Fire at most 1 Projectile"]={{flags=0,keywordFlags=0,name="NoAdditionalProjectiles",type="FLAG",value=true},nil}
8460+
c["Fire at most 1 Projectile"]={{[1]={flags=0,keywordFlags=0,name="SingleProjectile",type="FLAG",value=true}},nil}
84618461
c["First and Final shots of Barrage sequences fire Projectiles that Return to you"]={nil,"First and Final shots of Barrage sequences fire Projectiles that Return to you "}
84628462
c["Flammability can affect Hexproof Enemies"]={{[1]={[1]={skillId="Flammability",type="SkillId"},flags=0,keywordFlags=0,name="SkillData",type="LIST",value={key="ignoreHexproof",value=true}}},nil}
84638463
c["Flammability has no Reservation if Cast as an Aura"]={{[1]={[1]={skillId="Flammability",type="SkillId"},[2]={skillType=43,type="SkillType"},[3]={neg=true,skillType=119,type="SkillType"},flags=0,keywordFlags=0,name="SkillData",type="LIST",value={key="manaReservationFlat",value=0}},[2]={[1]={skillId="Flammability",type="SkillId"},[2]={skillType=43,type="SkillType"},[3]={neg=true,skillType=119,type="SkillType"},flags=0,keywordFlags=0,name="SkillData",type="LIST",value={key="lifeReservationFlat",value=0}},[3]={[1]={skillId="Flammability",type="SkillId"},[2]={skillType=43,type="SkillType"},[3]={neg=true,skillType=119,type="SkillType"},flags=0,keywordFlags=0,name="SkillData",type="LIST",value={key="manaReservationPercent",value=0}},[4]={[1]={skillId="Flammability",type="SkillId"},[2]={skillType=43,type="SkillType"},[3]={neg=true,skillType=119,type="SkillType"},flags=0,keywordFlags=0,name="SkillData",type="LIST",value={key="lifeReservationPercent",value=0}}},nil}

src/Data/Skills/act_dex.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16117,7 +16117,7 @@ skills["TornadoShot"] = {
1611716117
if activeSkill.skillPart == 2 and (output.ReturnChance or 0) == 0 then
1611816118
local averageSecondaryProjectiles = output.ProjectileCount + (output.SplitCount or 0)
1611916119
-- if barrage then only shoots 1 projectile at a time, but those can still split and still releases at least 1 secondary projectile
16120-
if activeSkill.skillModList:Flag(nil, "SequentialProjectiles") and not activeSkill.skillModList:Flag(nil, "OneShotProj") and not activeSkill.skillModList:Flag(nil,"NoAdditionalProjectiles") and not activeSkill.skillModList:Flag(nil, "TriggeredBySnipe") then
16120+
if activeSkill.skillModList:Flag(nil, "SequentialProjectiles") and not activeSkill.skillModList:Flag(nil, "OneShotProj") and not activeSkill.skillModList:Flag(nil,"NoAdditionalProjectiles") and not activeSkill.skillModList:Flag(nil,"SingleProjectile") and not activeSkill.skillModList:Flag(nil, "TriggeredBySnipe") then
1612116121
averageSecondaryProjectiles = 1 + (output.SplitCount or 0)
1612216122
end
1612316123
-- default to 20% per secondary projectile, so 60% base, and 80% with helm enchant

src/Modules/CalcOffence.lua

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -753,7 +753,7 @@ function calcs.offence(env, actor, activeSkill)
753753
skillModList:NewMod("AreaOfEffect", "INC", mod.value, mod.source, mod.flags, mod.keywordFlags, unpack(mod))
754754
end
755755
end
756-
if skillModList:Flag(nil, "SequentialProjectiles") and not skillModList:Flag(nil, "OneShotProj") and not skillModList:Flag(nil,"NoAdditionalProjectiles") and not skillModList:Flag(nil, "TriggeredBySnipe") then
756+
if skillModList:Flag(nil, "SequentialProjectiles") and not skillModList:Flag(nil, "OneShotProj") and not skillModList:Flag(nil,"NoAdditionalProjectiles") and not skillModList:Flag(nil,"SingleProjectile") and not skillModList:Flag(nil, "TriggeredBySnipe") then
757757
-- Applies DPS multiplier based on projectile count
758758
skillData.dpsMultiplier = skillModList:Sum("BASE", skillCfg, "ProjectileCount")
759759
end
@@ -997,7 +997,8 @@ function calcs.offence(env, actor, activeSkill)
997997
else
998998
output.ChainMax = skillModList:Sum("BASE", skillCfg, "ChainCountMax", not skillFlags.projectile and "BeamChainCountMax" or nil)
999999
if skillModList:Flag(skillCfg, "AdditionalProjectilesAddChainsInstead") then
1000-
output.ChainMax = output.ChainMax + m_floor((skillModList:Sum("BASE", skillCfg, "ProjectileCount") - 1) * skillModList:More(skillCfg, "ProjectileCount"))
1000+
local projCount = skillModList:Flag(skillCfg, "SingleProjectile") and 0 or m_floor((skillModList:Sum("BASE", skillCfg, "ProjectileCount") - 1) * skillModList:More(skillCfg, "ProjectileCount"))
1001+
output.ChainMax = output.ChainMax + projCount
10011002
end
10021003
output.ChainMaxString = output.ChainMax
10031004
output.Chain = m_min(output.ChainMax, skillModList:Sum("BASE", skillCfg, "ChainCount"))
@@ -1011,7 +1012,7 @@ function calcs.offence(env, actor, activeSkill)
10111012
if skillModList:Flag(nil, "FarShot") then
10121013
skillModList:NewMod("Damage", "MORE", 100, "Far Shot", bor(ModFlag.Attack, ModFlag.Projectile), { type = "DistanceRamp", ramp = {{10, -0.2}, {25, 0}, {70, 0.6}} })
10131014
end
1014-
if skillModList:Flag(skillCfg, "NoAdditionalProjectiles") then
1015+
if skillModList:Flag(skillCfg, "NoAdditionalProjectiles") or skillModList:Flag(skillCfg, "SingleProjectile") then
10151016
output.ProjectileCount = 1
10161017
else
10171018
local projMin = skillModList:Sum("BASE", skillCfg, "ProjectileCountMinimum")
@@ -1020,7 +1021,7 @@ function calcs.offence(env, actor, activeSkill)
10201021
output.ProjectileCount = m_max(m_floor(projBase * projMore), projMin)
10211022
end
10221023
if skillModList:Flag(skillCfg, "AdditionalProjectilesAddBouncesInstead") then
1023-
local projBase = skillModList:Sum("BASE", skillCfg, "ProjectileCount") + skillModList:Sum("BASE", skillCfg, "BounceCount") - 1
1024+
local projBase = skillModList:Flag(skillCfg, "SingleProjectile") and 0 or skillModList:Sum("BASE", skillCfg, "ProjectileCount") + skillModList:Sum("BASE", skillCfg, "BounceCount") - 1
10241025
local projMore = skillModList:More(skillCfg, "ProjectileCount")
10251026
output.BounceCount = m_floor(projBase * projMore)
10261027
end
@@ -1034,7 +1035,7 @@ function calcs.offence(env, actor, activeSkill)
10341035
else
10351036
output.SplitCount = skillModList:Sum("BASE", skillCfg, "SplitCount") + enemyDB:Sum("BASE", skillCfg, "SelfSplitCount")
10361037
if skillModList:Flag(skillCfg, "AdditionalProjectilesAddSplitsInstead") then
1037-
output.SplitCount = output.SplitCount + m_floor((skillModList:Sum("BASE", skillCfg, "ProjectileCount") - 1) * skillModList:More(skillCfg, "ProjectileCount"))
1038+
output.SplitCount = output.SplitCount + skillModList:Flag(skillCfg, "SingleProjectile") and 0 or m_floor((skillModList:Sum("BASE", skillCfg, "ProjectileCount") - 1) * skillModList:More(skillCfg, "ProjectileCount"))
10381039
end
10391040
if skillModList:Flag(skillCfg, "AdditionalChainsAddSplitsInstead") then
10401041
output.SplitCount = output.SplitCount + skillModList:Sum("BASE", skillCfg, "ChainCountMax")

src/Modules/CalcSections.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -653,7 +653,7 @@ return {
653653
{ label = "Reserve Uptime", haveOutput = "ReserveDurationUptime", { format = "{2:output:ReserveDurationUptime}%", { breakdown = "ReserveDurationUptime" }, }, },
654654
{ label = "Sustainable Trauma", haveOutput = "SustainableTrauma", { format = "{0:output:SustainableTrauma}", { breakdown = "SustainableTrauma" }, { modName = { "ExtraTrauma", "RepeatCount", "Duration", "PrimaryDuration", "SecondaryDuration"}, cfg = "skill" }, }, },
655655
{ label = "Repeat Count", haveOutput = "RepeatCount", { format = "{output:Repeats}", { modName = { "RepeatCount" }, cfg = "skill" }, }, },
656-
{ label = "Projectile Count", flag = "projectile", { format = "{output:ProjectileCount}", { modName = { "NoAdditionalProjectiles" , "ProjectileCount", "ProjectileCountMinimum" }, cfg = "skill" }, }, },
656+
{ label = "Projectile Count", flag = "projectile", { format = "{output:ProjectileCount}", { modName = { "NoAdditionalProjectiles", "SingleProjectile" , "ProjectileCount", "ProjectileCountMinimum" }, cfg = "skill" }, }, },
657657
{ label = "Pierce Count", haveOutput = "PierceCount", { format = "{output:PierceCountString}", { modName = { "CannotPierce", "PierceCount", "PierceAllTargets" }, cfg = "skill" }, }, },
658658
{ label = "Fork Count", haveOutput = "ForkCountMax", { format = "{output:ForkCountString}", { modName = { "CannotFork", "ForkCountMax" }, cfg = "skill" }, }, },
659659
{ label = "Max Chain Count", haveOutput = "ChainMax", { format = "{output:ChainMaxString}", { modName = { "CannotChain", "ChainCountMax", "NoAdditionalChains" }, cfg = "skill" }, }, },

src/Modules/ModParser.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4183,7 +4183,7 @@ local specialModList = {
41834183
["spells [hf][ai][vr]e an additional projectile"] = { mod("ProjectileCount", "BASE", 1, nil, ModFlag.Spell) },
41844184
["spells [hf][ai][vr]e (%d+) additional projectiles"] = function(num) return { mod("ProjectileCount", "BASE", num, nil, ModFlag.Spell) } end,
41854185
["attacks fire an additional projectile"] = { mod("ProjectileCount", "BASE", 1, nil, ModFlag.Attack) },
4186-
["fire at most 1 projectile"] = flag("NoAdditionalProjectiles"),
4186+
["fire at most 1 projectile"] = { flag("SingleProjectile") },
41874187
["attacks have an additional projectile when in off hand"] = { mod("ProjectileCount", "BASE", 1, nil, ModFlag.Attack, { type = "SlotNumber", num = 2 }) },
41884188
["caustic arrow and scourge arrow fire (%d+)%% more projectiles"] = function(num) return { mod("ProjectileCount", "MORE", num, nil, { type = "SkillName", skillNameList = { "Caustic Arrow", "Scourge Arrow" }, includeTransfigured = true }) } end,
41894189
["essence drain and soulrend fire (%d+) additional projectiles"] = function(num) return { mod("ProjectileCount", "BASE", num, nil, { type = "SkillName", skillNameList = { "Essence Drain", "Soulrend" }, includeTransfigured = true }) } end,

0 commit comments

Comments
 (0)