Mercurial > wow > itemauditor
comparison Modules/DisplayInvested.lua @ 159:fbfd9dfa6d2b tip
[mq]: minorStuff
author | Asa Ayers <Asa.Ayers@Gmail.com> |
---|---|
date | Sun, 09 Jan 2011 07:38:22 -0800 |
parents | 106c1523777e |
children |
comparison
equal
deleted
inserted
replaced
158:7ebe0a85d539 | 159:fbfd9dfa6d2b |
---|---|
190 | 190 |
191 local inventory = ItemAuditor:GetCurrentInventory() | 191 local inventory = ItemAuditor:GetCurrentInventory() |
192 | 192 |
193 for itemID, count in pairs(inventory.items) do | 193 for itemID, count in pairs(inventory.items) do |
194 if includedItems[itemID] == nil then | 194 if includedItems[itemID] == nil then |
195 assert(itemID ~= 0, 'Invalid ItemID. Something may be wrong in the inventory scanner.') | |
195 local itemName, link = GetItemInfo(itemID) | 196 local itemName, link = GetItemInfo(itemID) |
197 if not link then | |
198 -- we can't continue without a link, but sometimes blizzard just fails to return one. | |
199 ItemAuditor:Print("GetItemInfo failed to return an item link for %s (ID: %s). Retrying in 1 second.", tostring(itemName), tostring(itemID)) | |
200 return ItemAuditor:ScheduleTimer(UpdateInvestedData, 1) | |
201 end | |
202 assert(link, format("failed to get link for %s:%s", tostring(itemID), tostring(itemName))) | |
196 local count = ItemAuditor:GetItemCount(itemID) | 203 local count = ItemAuditor:GetItemCount(itemID) |
197 tableData[i] = { | 204 tableData[i] = { |
198 itemName.."|"..link, | 205 itemName.."|"..link, |
199 0, | 206 0, |
200 0, | 207 0, |