Mercurial > wow > askmrrobot
diff TeamOptimizer.lua @ 96:e0ddd02d6555 v45
tweak to ignore some junk in team optimizer loot export
author | yellowfive |
---|---|
date | Sat, 01 Oct 2016 15:48:00 -0700 |
parents | adec0972d4e1 |
children | ed7ffc8d9936 |
line wrap: on
line diff
--- a/TeamOptimizer.lua Fri Sep 23 18:29:56 2016 -0700 +++ b/TeamOptimizer.lua Sat Oct 01 15:48:00 2016 -0700 @@ -794,6 +794,11 @@ Amr.db.global.TeamOpt.LootGear = newInfo end +local _ignoreLoot = { + [139562] = true, + [136903] = true +} + local function scanMasterLoot() -- only care if we are in a raid or group if not IsInGroup() and not IsInRaid() then return end @@ -817,7 +822,13 @@ local lootType = GetLootSlotType(i) if lootType == 1 then local link = GetLootSlotLink(i) - table.insert(loot, link) + local success, itemObj = pcall(Amr.ParseItemLink, link) + + if not success or not itemObj or _ignoreLoot[itemObj.id] then + -- ignore items that can't be read or that we explicitly don't care about + else + table.insert(loot, link) + end end end