Skip to content

Commit a8664fd

Browse files
author
LocalIdentity
committed
Update query mods to work for spears and flails
1 parent 1f945d4 commit a8664fd

File tree

2 files changed

+2494
-1812
lines changed

2 files changed

+2494
-1812
lines changed

src/Classes/TradeQueryGenerator.lua

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ local tradeCategoryNames = {
2222
["Quiver"] = { "Quiver" },
2323
["Shield"] = { "Shield" },
2424
["Focus"] = { "Focus" },
25-
["1HWeapon"] = { "One Handed Mace", "Wand", "Sceptre" },
25+
["1HWeapon"] = { "One Handed Mace", "Wand", "Sceptre", "Flail", "Spear" },
2626
["2HWeapon"] = { "Staff", "Staff: Warstaff", "Two Handed Mace", "Crossbow", "Bow" },
2727
-- ["1HAxe"] = { "One Handed Axe" },
2828
-- ["1HSword"] = { "One Handed Sword", "Thrusting One Handed Sword" },
@@ -48,8 +48,8 @@ local tradeCategoryNames = {
4848
-- ["RadiusJewel"] = { "Jewel: Radius" },
4949
-- not in the game yet.
5050
-- ["TrapTool"] = { "TrapTool"}, Unsure if correct
51-
-- ["Flail"] = { "Flail" },
52-
-- ["Spear"] = { "Spear" }
51+
["Flail"] = { "Flail" },
52+
["Spear"] = { "Spear" }
5353
}
5454

5555
-- Build lists of tags present on a given item category
@@ -414,7 +414,7 @@ function TradeQueryGeneratorClass:InitMods()
414414
-- rune mods
415415
for name, modLines in pairs(data.itemMods.Runes) do
416416
self:ProcessMod(modLines.armour, tradeQueryStatsParsed, regularItemMask, { ["Shield"] = true, ["Chest"] = true, ["Helmet"] = true, ["Gloves"] = true, ["Boots"] = true, ["Focus"] = true })
417-
self:ProcessMod(modLines.weapon, tradeQueryStatsParsed, regularItemMask, { ["1HWeapon"] = true, ["2HWeapon"] = true, ["1HMace"] = true, ["Claw"] = true, ["Quarterstaff"] = true, ["Bow"] = true, ["2HMace"] = true, ["Crossbow"] = true })
417+
self:ProcessMod(modLines.weapon, tradeQueryStatsParsed, regularItemMask, { ["1HWeapon"] = true, ["2HWeapon"] = true, ["1HMace"] = true, ["Claw"] = true, ["Quarterstaff"] = true, ["Bow"] = true, ["2HMace"] = true, ["Crossbow"] = true, ["Spear"] = true, ["Flail"] = true })
418418
end
419419

420420
local queryModsFile = io.open(queryModFilePath, 'w')
@@ -559,7 +559,7 @@ function TradeQueryGeneratorClass:StartQuery(slot, options)
559559
elseif existingItem.type == "Focus" then
560560
itemCategoryQueryStr = "armour.focus"
561561
itemCategory = "Focus"
562-
elseif existingItem.type == "Buckler" then -- not in game
562+
elseif existingItem.type == "Buckler" then
563563
itemCategoryQueryStr = "armour.buckler"
564564
itemCategory = "Buckler"
565565
elseif existingItem.type == "Quiver" then
@@ -592,10 +592,10 @@ function TradeQueryGeneratorClass:StartQuery(slot, options)
592592
elseif existingItem.type == "One Handed Sword" then
593593
itemCategoryQueryStr = "weapon.onesword"
594594
itemCategory = "1HSword"
595-
elseif existingItem.type == "Spear" then -- not in game
595+
elseif existingItem.type == "Spear" then
596596
itemCategoryQueryStr = "weapon.spear"
597-
itemCategory = "1HSword"
598-
elseif existingItem.type == "Flail" then -- not in game
597+
itemCategory = "Spear"
598+
elseif existingItem.type == "Flail" then
599599
itemCategoryQueryStr = "weapon.flail"
600600
itemCategory = "weapon.flail"
601601
elseif existingItem.type == "One Handed Axe" then

0 commit comments

Comments
 (0)