View Single Post
08-19-18, 01:23 AM   #11
gmarco
An Onyxian Warder
 
gmarco's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2009
Posts: 362
Originally Posted by dssd View Post
To answer your question on the name, this is how Blizzard does it.
Code:
local azeriteItemLocation = C_AzeriteItem.FindActiveAzeriteItem()
if azeriteItemLocation then
    local azeriteItem = Item:CreateFromItemLocation(azeriteItemLocation);
    print(azeriteItem:GetItemName())
end
I have seen this but I had not understood very well what the line:

Lua Code:
  1. local azeriteItem = Item:CreateFromItemLocation(azeriteItemLocation);

did.

Now I see it creates an obj item and then I can get the name with :GetItemName())
It is a so different approach from legion artifact ... who knows why they change so much ? :)

Btw it works :))

Thanks so much to everyone.
__________________
This is Unix-Land. In quiet nights, you can hear the Windows machines reboot.
  Reply With Quote