Thread: Item Mixins
View Single Post
10-18-18, 10:05 AM   #2
MuffinManKen
A Flamescale Wyrmkin
AddOn Author - Click to view addons
Join Date: Dec 2009
Posts: 106
The mixin isn't doing any magic here. If you look at the GetCurrentItemLevel call from the mixin:
Lua Code:
  1. function ItemMixin:GetCurrentItemLevel() -- requires item data to be loaded
  2.     if self.itemLink then
  3.         return (GetDetailedItemLevelInfo(self.itemLink));
  4.     end
  5.     if not self:IsItemEmpty() then
  6.         return C_Item.GetCurrentItemLevel(self:GetItemLocation());
  7.     end
  8.     return nil;
  9. end
You can see it's just calling GetDetailedItemLevelInfo with an item link. So item links *do* work, you just need the right one. The link encodes a bunch of info in addition to the item id and I would guess that it needs that. Looking at the definition of an itemstring, (http://wowwiki.wikia.com/wiki/ItemString) "linkLevel" might be the important bit.
  Reply With Quote