Skip to content

Commit 9ba3f05

Browse files
committed
Parse martial artist flag mod from tree and fix selector pos
1 parent 69324f7 commit 9ba3f05

3 files changed

Lines changed: 14 additions & 24 deletions

File tree

src/Classes/ItemsTab.lua

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -149,8 +149,11 @@ local ItemsTabClass = newClass("ItemsTab", "UndoHandler", "ControlHost", "Contro
149149
-- PoB Trader class initialization
150150
self.tradeQuery = new("TradeQuery", self)
151151

152+
-- x offset for all of the left side itemtab controls since they are
153+
-- anchored to one another from top to bottom
154+
local selectorsXOffset = 109
152155
-- Set selector
153-
self.controls.setSelect = new("DropDownControl", {"TOPLEFT",self,"TOPLEFT"}, {96, 8, 216, 20}, nil, function(index, value)
156+
self.controls.setSelect = new("DropDownControl", {"TOPLEFT",self,"TOPLEFT"}, { selectorsXOffset, 8, 216, 20 }, nil, function(index, value)
154157
self:SetActiveItemSet(self.itemSetOrderList[index])
155158
self:AddUndoState()
156159
end)
@@ -170,7 +173,7 @@ local ItemsTabClass = newClass("ItemsTab", "UndoHandler", "ControlHost", "Contro
170173
end)
171174

172175
-- Price Items
173-
self.controls.priceDisplayItem = new("ButtonControl", {"TOPLEFT",self,"TOPLEFT"}, {96, 32, 310, 20}, "Trade for these items", function()
176+
self.controls.priceDisplayItem = new("ButtonControl", {"TOPLEFT",self,"TOPLEFT"}, { selectorsXOffset, 32, 310, 20 }, "Trade for these items", function()
174177
self.tradeQuery:PriceItem()
175178
end)
176179
self.controls.priceDisplayItem.tooltipFunc = function(tooltip)
@@ -242,7 +245,7 @@ local ItemsTabClass = newClass("ItemsTab", "UndoHandler", "ControlHost", "Contro
242245
self.slotOrder = { }
243246
self.runeSlots = { }
244247
self.initSockets = true
245-
self.slotAnchor = new("Control", {"TOPLEFT",self,"TOPLEFT"}, {96, 76, 310, 0})
248+
self.slotAnchor = new("Control", {"TOPLEFT",self,"TOPLEFT"}, {selectorsXOffset, 76, 310, 0})
246249
local prevSlot = self.slotAnchor
247250
local function addSlot(slot)
248251
prevSlot = slot

src/Data/ModCache.lua

Lines changed: 5 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -952,13 +952,8 @@ c["0% to Fire Resistance"]={{[1]={flags=0,keywordFlags=0,name="FireResist",type=
952952
c["0% to Lightning Resistance"]={{[1]={flags=0,keywordFlags=0,name="LightningResist",type="BASE",value=0}},"% to "}
953953
c["0.1 Life Regeneration per second"]={{[1]={flags=0,keywordFlags=0,name="LifeRegen",type="BASE",value=0.1}},nil}
954954
c["0.5% of maximum Life Regenerated per second per Fragile Regrowth"]={{[1]={[1]={type="Multiplier",var="FragileRegrowthCount"},flags=0,keywordFlags=0,name="LifeRegenPercent",type="BASE",value=0.5}},nil}
955-
c["1 Boots socket"]={{}," Boots socket "}
956-
c["1 Gloves socket"]={{}," Gloves socket "}
957-
c["1 Gloves socket 1 Boots socket"]={{}," Gloves socket 1 Boots socket "}
958-
c["1 Helmet socket"]={{}," Helmet socket "}
959-
c["1 Helmet socket 2 Body Armour sockets"]={{[1]={flags=0,keywordFlags=0,name="Armour",type="BASE",value=1}}," Helmet socket 2 Body sockets "}
960-
c["1 Helmet socket 2 Body Armour sockets 1 Gloves socket"]={{[1]={flags=0,keywordFlags=0,name="Armour",type="BASE",value=1}}," Helmet socket 2 Body sockets 1 Gloves socket "}
961-
c["1 Helmet socket 2 Body Armour sockets 1 Gloves socket 1 Boots socket"]={{[1]={flags=0,keywordFlags=0,name="Armour",type="BASE",value=1}}," Helmet socket 2 Body sockets 1 Gloves socket 1 Boots socket "}
955+
c["1 Boots socket"]={{},nil}
956+
c["1 Helmet socket"]={{},nil}
962957
c["1 Rage Regenerated for every 25 Mana Regeneration per Second"]={{[1]={[1]={div=25,stat="ManaRegen",type="PerStat"},flags=0,keywordFlags=0,name="RageRegen",type="BASE",value=1},[2]={flags=0,keywordFlags=0,name="Condition:CanGainRage",type="FLAG",value=true}},nil}
963958
c["1% chance when you gain a Charge to gain an additional Charge per 10 Tribute"]={{}," when you gain a Charge to gain an additional Charge "}
964959
c["1% increased Area of Effect for Attacks per 10 Intelligence"]={{[1]={[1]={div=10,stat="Int",type="PerStat"},flags=1,keywordFlags=0,name="AreaOfEffect",type="INC",value=1}},nil}
@@ -1774,8 +1769,7 @@ c["18% reduced Attack Speed"]={{[1]={flags=1,keywordFlags=0,name="Speed",type="I
17741769
c["19% increased Cast Speed"]={{[1]={flags=16,keywordFlags=0,name="Speed",type="INC",value=19}},nil}
17751770
c["195% increased Physical Damage"]={{[1]={flags=0,keywordFlags=0,name="PhysicalDamage",type="INC",value=195}},nil}
17761771
c["2 Body Armour sockets"]={{[1]={flags=0,keywordFlags=0,name="Armour",type="BASE",value=2}}," Body sockets "}
1777-
c["2 Body Armour sockets 1 Gloves socket"]={{[1]={flags=0,keywordFlags=0,name="Armour",type="BASE",value=2}}," Body sockets 1 Gloves socket "}
1778-
c["2 Body Armour sockets 1 Gloves socket 1 Boots socket"]={{[1]={flags=0,keywordFlags=0,name="Armour",type="BASE",value=2}}," Body sockets 1 Gloves socket 1 Boots socket "}
1772+
c["2 Body Armour sockets 1 Gloves socket"]={{},nil}
17791773
c["2% chance that if you would gain Endurance Charges, you instead gain up to maximum Endurance Charges"]={{[1]={flags=0,keywordFlags=0,name="FlaskCharges",type="BASE",value=2}}," that if you would gain Endurance , you instead gain up to maximum Endurance Charges "}
17801774
c["2% chance that if you would gain Endurance Charges, you instead gain up to maximum Endurance Charges +1 to Maximum Endurance Charges"]={{[1]={flags=0,keywordFlags=0,name="FlaskCharges",type="BASE",value=2}}," that if you would gain Endurance , you instead gain up to maximum Endurance Charges +1 to Maximum Endurance Charges "}
17811775
c["2% chance that if you would gain Frenzy Charges, you instead gain up to your maximum number of Frenzy Charges"]={{[1]={flags=0,keywordFlags=0,name="FlaskCharges",type="BASE",value=2}}," that if you would gain Frenzy , you instead gain up to your maximum number of Frenzy Charges "}
@@ -4711,12 +4705,7 @@ c["Can have up to one Unique Tamed Beast summoned Unique Tamed Beasts have 30% i
47114705
c["Can instead consume 25% of maximum Mana to trigger Charms with insufficient charges"]={nil,"Can instead consume 25% of maximum Mana to trigger Charms with insufficient charges "}
47124706
c["Can only use a Normal Body Armour"]={nil,"Can only use a Normal Body Armour "}
47134707
c["Can only use a Normal Body Armour +200 to Armour for each Connected Notable Passive Skill Allocated"]={nil,"Can only use a Normal Body Armour +200 to Armour for each Connected Notable Passive Skill Allocated "}
4714-
c["Can tattoo Runes onto your body, gaining"]={nil,"Can tattoo Runes onto your body, gaining "}
4715-
c["Can tattoo Runes onto your body, gaining additional Rune-only sockets:"]={nil,"Can tattoo Runes onto your body, gaining additional Rune-only sockets: "}
4716-
c["Can tattoo Runes onto your body, gaining additional Rune-only sockets: 1 Helmet socket"]={nil,"Can tattoo Runes onto your body, gaining additional Rune-only sockets: 1 Helmet socket "}
4717-
c["Can tattoo Runes onto your body, gaining additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets"]={nil,"Can tattoo Runes onto your body, gaining additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets "}
4718-
c["Can tattoo Runes onto your body, gaining additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets 1 Gloves socket"]={nil,"Can tattoo Runes onto your body, gaining additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets 1 Gloves socket "}
4719-
c["Can tattoo Runes onto your body, gaining additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets 1 Gloves socket 1 Boots socket"]={nil,"Can tattoo Runes onto your body, gaining additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets 1 Gloves socket 1 Boots socket "}
4708+
c["Can tattoo Runes onto your body, gaining"]={{[1]={flags=0,keywordFlags=0,name="SocketRunesOnCharacter",type="FLAG",value=true}},nil}
47204709
c["Can't use Body Armour"]={{[1]={[1]={slotName="Body Armour",type="DisablesItem"},flags=0,keywordFlags=0,name="CanNotUseBody",type="Flag",value=1}},nil}
47214710
c["Can't use Helmets"]={nil,"Can't use Helmets "}
47224711
c["Can't use Helmets Your Critical Hit Chance is Lucky"]={nil,"Can't use Helmets Your Critical Hit Chance is Lucky "}
@@ -6585,11 +6574,7 @@ c["Your base Energy Shield Recharge Delay is 10 seconds"]={{[1]={flags=0,keyword
65856574
c["Your speed is unaffected by Slows"]={{[1]={flags=0,keywordFlags=0,name="UnaffectedBySlows",type="FLAG",value=true}},nil}
65866575
c["Zealot's Oath"]={{[1]={flags=0,keywordFlags=0,name="Keystone",type="LIST",value="Zealot's Oath"}},nil}
65876576
c["additional Elemental Infusion of the same type"]={nil,"additional Elemental Infusion of the same type "}
6588-
c["additional Rune-only sockets:"]={nil,"additional Rune-only sockets: "}
6589-
c["additional Rune-only sockets: 1 Helmet socket"]={nil,"additional Rune-only sockets: 1 Helmet socket "}
6590-
c["additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets"]={nil,"additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets "}
6591-
c["additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets 1 Gloves socket"]={nil,"additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets 1 Gloves socket "}
6592-
c["additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets 1 Gloves socket 1 Boots socket"]={nil,"additional Rune-only sockets: 1 Helmet socket 2 Body Armour sockets 1 Gloves socket 1 Boots socket "}
6577+
c["additional Rune-only sockets:"]={{},nil}
65936578
c["being Shapeshifted for at least 8 seconds"]={nil,"being Shapeshifted for at least 8 seconds "}
65946579
c["for 4 seconds, every 0.25 seconds while raised"]={nil,"for 4 seconds, every 0.25 seconds while raised "}
65956580
c["gain 6 Cold Surges or 6 Fire Surges"]={{}," Cold Surges or 6 Fire Surges "}

src/Modules/ModParser.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6137,7 +6137,9 @@ local specialModList = {
61376137
["you can socket an additional copy of each lineage support gem, in different skills"] = { mod("MaxLineageCount", "BASE", 1) },
61386138
["you can socket (%d+) additional copies of each lineage support gem, in different skills"] = function(num) return { mod("MaxLineageCount", "BASE", num) } end,
61396139
["can be modified while corrupted"] = {},
6140-
["can tattoo runes"] = { flag("SocketRunesOnCharacter") },
6140+
["can tattoo runes onto your body, gaining"] = { flag("SocketRunesOnCharacter") },
6141+
["additional rune%-only sockets:"] = {},
6142+
["(%d+) (.+) socket"] = {}
61416143
}
61426144
for _, name in pairs(data.keystones) do
61436145
specialModList[name:lower()] = { mod("Keystone", "LIST", name) }

0 commit comments

Comments
 (0)