Skip to content

Commit 997b856

Browse files
justjuanguijustjuanguiLocalIdentity
authored
Enable Hulking form ascendancy (#171)
* Enable Hulking form ascendancy * Move mods --------- Co-authored-by: justjuangui <servicios@juacarvajal.com> Co-authored-by: LocalIdentity <localidentity2@gmail.com>
1 parent a5ad54b commit 997b856

File tree

3 files changed

+24
-8
lines changed

3 files changed

+24
-8
lines changed

src/Data/ModCache.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1830,7 +1830,7 @@ c["50% increased Totem Placement range"]={{[1]={flags=0,keywordFlags=16384,name=
18301830
c["50% increased Weapon Swap Speed"]={{[1]={flags=0,keywordFlags=0,name="WeaponSwapSpeed",type="INC",value=50}},nil}
18311831
c["50% increased amount of Mana Leeched"]={{[1]={flags=0,keywordFlags=0,name="ManaLeech",type="INC",value=50}},nil}
18321832
c["50% increased chance to Ignite"]={{[1]={flags=0,keywordFlags=0,name="EnemyIgniteChance",type="INC",value=50}},nil}
1833-
c["50% increased effect of Small Passive Skills"]={{[1]={flags=0,keywordFlags=0,name="LocalEffect",type="INC",value=50}}," of Small Passive Skills "}
1833+
c["50% increased effect of Small Passive Skills"]={{[1]={flags=0,keywordFlags=0,name="SmallPassiveSkillEffect",type="INC",value=50}},nil}
18341834
c["50% increased effect of Sorcery Ward"]={{[1]={[1]={includeTransfigured=true,skillName="Sorcery Ward",type="SkillName"},flags=0,keywordFlags=0,name="LocalEffect",type="INC",value=50}}," of"}
18351835
c["50% increased effect of Sorcery Ward Sorcery Ward recovers 50% faster"]={{[1]={[1]={includeTransfigured=true,skillName="Sorcery Ward",type="SkillName"},flags=0,keywordFlags=0,name="LocalEffect",type="INC",value=50}}," ofSorcery Ward recovers 50% faster "}
18361836
c["50% increased maximum Dash Distance with Unarmed Attack Skills"]={{}," maximum Dash Distance with Attack Skills "}

src/Modules/CalcSetup.lua

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ function calcs.initModDB(env, modDB)
9090
modDB.conditions["Effective"] = env.mode_effective
9191
end
9292

93-
function calcs.buildModListForNode(env, node)
93+
function calcs.buildModListForNode(env, node, incSmallPassiveSkill)
9494
local modList = new("ModList")
9595
if node.type == "Keystone" then
9696
modList:AddMod(node.keystoneMod)
@@ -164,6 +164,14 @@ function calcs.buildModListForNode(env, node)
164164
t_insert(env.explodeSources, node)
165165
end
166166

167+
-- Apply Inc Node scaling from Hulking Form
168+
if incSmallPassiveSkill > 0 and node.type == "Normal" and not node.isAttribute and not node.ascendancyName then
169+
local scale = 1 + incSmallPassiveSkill / 100
170+
local scaledList = new("ModList")
171+
scaledList:ScaleAddList(modList, scale)
172+
modList = scaledList
173+
end
174+
167175
return modList
168176
end
169177

@@ -175,10 +183,16 @@ function calcs.buildModListForNodeList(env, nodeList, finishJewels)
175183
rad.data.modSource = "Tree:"..rad.nodeId
176184
end
177185

186+
-- calculate inc from SmallPassiveSkillEffect
187+
local inc = 0
188+
for _, node in pairs(nodeList) do
189+
inc = inc + node.modList:Sum("INC", nil ,"SmallPassiveSkillEffect")
190+
end
191+
178192
-- Add node modifiers
179193
local modList = new("ModList")
180194
for _, node in pairs(nodeList) do
181-
local nodeModList = calcs.buildModListForNode(env, node)
195+
local nodeModList = calcs.buildModListForNode(env, node, inc)
182196
modList:AddList(nodeModList)
183197
if env.mode == "MAIN" then
184198
node.finalModList = nodeModList
@@ -188,7 +202,7 @@ function calcs.buildModListForNodeList(env, nodeList, finishJewels)
188202
if finishJewels then
189203
-- Process extra radius nodes; these are unallocated nodes near conversion or threshold jewels that need to be processed
190204
for _, node in pairs(env.extraRadiusNodeList) do
191-
local nodeModList = calcs.buildModListForNode(env, node)
205+
local nodeModList = calcs.buildModListForNode(env, node, inc)
192206
if env.mode == "MAIN" then
193207
node.finalModList = nodeModList
194208
end

src/Modules/ModParser.lua

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2652,6 +2652,10 @@ local specialModList = {
26522652
["cannot be slowed to below base speed"] = { mod("MinimumActionSpeed", "MAX", 100, { type = "GlobalEffect", effectType = "Global", unscalable = true }) },
26532653
["gain accuracy rating equal to your strength"] = { mod("Accuracy", "BASE", 1, { type = "PerStat", stat = "Str" }) },
26542654
["gain accuracy rating equal to twice your strength"] = { mod("Accuracy", "BASE", 2, { type = "PerStat", stat = "Str" }) },
2655+
-- Mercenary
2656+
-- +2 Weapon Set Passive Skill Points
2657+
["%+(%d) weapon set passive skill points"] = function(num) return { mod("WeaponSetPassivePoints", "BASE", num) } end,
2658+
["(%d+) passive skill points become weapon set skill points"] = function(num) return { mod("PassivePointsToWeaponSetPoints", "BASE", num) } end,
26552659
-- Necromancer
26562660
["your offering skills also affect you"] = { mod("ExtraSkillMod", "LIST", { mod = mod("SkillData", "LIST", { key = "buffNotPlayer", value = false }) }, { type = "SkillName", skillNameList = { "Bone Offering", "Flesh Offering", "Spirit Offering", "Blood Offering" } }) },
26572661
["your offerings have (%d+)%% reduced effect on you"] = function(num) return { mod("ExtraSkillMod", "LIST", { mod = mod("BuffEffectOnPlayer", "INC", -num) }, { type = "SkillName", skillNameList = { "Bone Offering", "Flesh Offering", "Spirit Offering", "Blood Offering" } }) } end,
@@ -2736,6 +2740,8 @@ local specialModList = {
27362740
["gain (%d+)%% increased attack speed for 20 seconds when you kill a rare or unique enemy"] = function(num) return { mod("Speed", "INC", num, nil, ModFlag.Attack, 0, { type = "Condition", var = "KilledUniqueEnemy" }) } end,
27372741
["kill enemies that have (%d+)%% or lower life when hit by your skills"] = function(num) return { mod("CullPercent", "MAX", num) } end,
27382742
["you are unaffected by bleeding while leeching"] = { mod("SelfBleedEffect", "MORE", -100, { type = "Condition", var = "Leeching" }) },
2743+
-- Titan
2744+
["(%d+)%% increased effect of small passive skills"] = function(num) return { mod("SmallPassiveSkillEffect", "INC", num) } end,
27392745
-- Trickster
27402746
["(%d+)%% chance to gain (%d+)%% of non%-chaos damage with hits as extra chaos damage"] = function(num, _, perc) return { mod("NonChaosDamageGainAsChaos", "BASE", num / 100 * tonumber(perc)) } end,
27412747
["movement skills cost no mana"] = { mod("ManaCost", "MORE", -100, nil, 0, KeywordFlag.Movement) },
@@ -5155,10 +5161,6 @@ local specialModList = {
51555161
["nearby allies have (%d+)%% chance to block attack damage per (%d+) strength you have"] = function(block, _, str) return {
51565162
mod("ExtraAura", "LIST", { onlyAllies = true, mod = mod("BlockChance", "BASE", block) }, { type = "PerStat", stat = "Str", div = tonumber(str) }),
51575163
} end,
5158-
-- +2 Weapon Set Passive Skill Points
5159-
["%+(%d) weapon set passive skill points"] = function(num) return { mod("WeaponSetPassivePoints", "BASE", num) } end,
5160-
-- 20 Passive Skill Points become Weapon Set Skill Points
5161-
["(%d+) passive skill points become weapon set skill points"] = function(num) return { mod("PassivePointsToWeaponSetPoints", "BASE", num) } end,
51625164
}
51635165
for _, name in pairs(data.keystones) do
51645166
specialModList[name:lower()] = { mod("Keystone", "LIST", name) }

0 commit comments

Comments
 (0)