Skip to content

Commit 7c4f6ad

Browse files
author
David Medgyesy
committed
Align the Augyre dropdown with the default buff
Refs #10431
1 parent bfee69d commit 7c4f6ad

2 files changed

Lines changed: 28 additions & 1 deletion

File tree

‎spec/System/TestConfigTab_spec.lua‎

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -357,6 +357,32 @@ describe("TestConfig", function()
357357
end)
358358

359359
describe("Default values", function()
360+
it("defaults Augyre to Resolute Technique and preserves the Elemental Overload selection", function()
361+
build.skillsTab:PasteSocketGroup("Arc 20/0 1\n")
362+
local item = new("Item"):Item([[
363+
Rarity: UNIQUE
364+
Augyre
365+
Void Sceptre
366+
Implicits: 0
367+
Every 16 seconds you gain Elemental Overload for 8 seconds
368+
You have Resolute Technique while you do not have Elemental Overload]])
369+
build.itemsTab:AddItem(item, true)
370+
build.itemsTab.slots["Weapon 1"]:SetSelItemId(item.id)
371+
runCallback("OnFrame")
372+
373+
local control = build.configTab.varControls.conditionHaveAugyre
374+
assert.are.equal("ResTechnique", control:GetSelValueByKey("val"))
375+
assert.are.equal(0, build.calcsTab.mainOutput.CritChance)
376+
377+
control:SetSel(2)
378+
runCallback("OnFrame")
379+
assert.is_true(build.calcsTab.mainOutput.CritChance > 0)
380+
381+
loadBuildFromXML(build:SaveDB("code"))
382+
assert.are.equal("EleOverload", build.configTab.input.conditionHaveAugyre)
383+
assert.is_true(build.calcsTab.mainOutput.CritChance > 0)
384+
end)
385+
360386
it("Initializes new config sets with default placeholder states", function()
361387
assert.is_not_nil(build.configTab.configSets[1])
362388
assert.is_not_nil(build.configTab.configSets[1].input)

‎src/Modules/ConfigOptions.lua‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1695,7 +1695,8 @@ Huge sets the radius to 11.
16951695
modList:NewMod("Condition:HaveIronReflexes", "FLAG", true, "Config", { type = "Condition", var = "Combat" })
16961696
modList:NewMod("Keystone", "LIST", "Iron Reflexes", "Config")
16971697
end },
1698-
{ var = "conditionHaveAugyre", type = "list", label = "Augyre rotating buff:", ifFlag = "Condition:HaveAugyre", list = {{val="EleOverload",label="Elemental Overload"},{val="ResTechnique",label="Resolute Technique"}}, tooltip = "This option is specific to Augyre.", apply = function(val, modList, enemyModList)
1698+
-- The item's own modifier grants Resolute Technique when no buff is selected.
1699+
{ var = "conditionHaveAugyre", type = "list", label = "Augyre rotating buff:", ifFlag = "Condition:HaveAugyre", list = {{val="ResTechnique",label="Resolute Technique"},{val="EleOverload",label="Elemental Overload"}}, tooltip = "This option is specific to Augyre.", apply = function(val, modList, enemyModList)
16991700
if val == "EleOverload" then
17001701
modList:NewMod("Condition:HaveElementalOverload", "FLAG", true, "Config", { type = "Condition", var = "Combat" })
17011702
modList:NewMod("Keystone", "LIST", "Elemental Overload", "Config")

0 commit comments

Comments
 (0)