Mercurial > wow > itemauditor
comparison Core.lua @ 145:b15c19200af8
Fixed item links for 4.0.1
author | Asa Ayers <Asa.Ayers@Gmail.com> |
---|---|
date | Tue, 12 Oct 2010 18:04:57 -0700 |
parents | 03e108d12ef1 |
children | 1db61fa6be07 |
comparison
equal
deleted
inserted
replaced
144:03e108d12ef1 | 145:b15c19200af8 |
---|---|
588 if itemID ~= nil then | 588 if itemID ~= nil then |
589 _, newLink = GetItemInfo(itemID) | 589 _, newLink = GetItemInfo(itemID) |
590 return self:GetSafeLink(newLink) | 590 return self:GetSafeLink(newLink) |
591 end | 591 end |
592 end | 592 end |
593 return newLink and string.gsub(newLink, ":0:0:0:0:0:0", "") | 593 return newLink and string.gsub(newLink, ":0:0:0:0:0:0", ""):gsub(":[0-9]+$", "") |
594 end | 594 end |
595 | 595 |
596 function ItemAuditor:GetIDFromLink(link) | 596 function ItemAuditor:GetIDFromLink(link) |
597 local _, _, _, _, Id = string.find(link, "|?c?f?f?(%x*)|?H?([^:]*):?(%d+):?(%d*):?(%d*):?(%d*):?(%d*):?(%d*):?(%-?%d*):?(%-?%d*):?(%d*)|?h?%[?([^%[%]]*)%]?|?h?|?r?") | 597 local _, _, _, _, Id = string.find(link, "|?c?f?f?(%x*)|?H?([^:]*):?(%d+):?(%d*):?(%d*):?(%d*):?(%d*):?(%d*):?(%-?%d*):?(%-?%d*):?(%d*)|?h?%[?([^%[%]]*)%]?|?h?|?r?") |
598 return tonumber(Id) | 598 return tonumber(Id) |