New artifact API
Hi all,
is the function HasArtifactEquipped and all the C_ArtifactUI.* valid only for legion artifacts ? I'd like to check infos of the new neck in BFA. Where can I find the way to read it ? It is really very frustrating that blizzard don't provide an official documentation of their api and the changes they do (or probably I am not able to find them :) Thanks again to all for attention. |
/api ArtifactUI list
Edit: There is an addon for browsing the functions in a nice window. But I dont remember its name ;) Edit2: https://www.curseforge.com/wow/addons/apiinterface |
Thanks so much.
Never known about it :) |
Hi,
After the advice on /api helper :) I easily succeded in implement a simple tracking of the new artifact in my LDB gmexp. The only thing that I am unable to do is to get the name ("HEART OF AZEROTH") from the item :) Is it defined as a global value G_* ? Now I have made an ugly string but I'd like to avoid a variable to prevent to localize it by hand. Lua Code:
Thanks to everyone for attention. |
I've not yet tested the api ... but the name of the item should still be available through the item-api.
Code:
local itemName = GetItemInfo(GetInventoryItemID("player", INVSLOT_NECK)) |
Hi,
thanks for your answer ... it works nicely but it supposes that we always wear the artifact neck ( HEART OF AZEROTH :) This happens when I change it :) , for another set for example . So I was looking for a specific "azerite" function that give me back the name of the azerite artifact like the old one works before: Lua Code:
Btw thanks for the input. It is much appreciated. |
Check for the itemID, if it's not the heart necklace then abort :p
|
Thinking about itemID ...
I can just write something like: Lua Code:
... and cross fingers about Blizzard doesn't change itemiID of Heart of Azeroth in the next steps ... Any others ideas ? :) |
In BfA there's two new Lua API namespaces for Azerite items.
The necklace is considered an "Azerite Item" and is under the C_AzeriteItem namespace, see /api AzeriteItem The other pieces that are powered by the necklace are considered "Azerite Empowered Items" and are in the C_AzeriteEmpoweredItem namespace, see /api AzeriteEmpoweredItem To answer your question on the name, this is how Blizzard does it. Code:
local azeriteItemLocation = C_AzeriteItem.FindActiveAzeriteItem() |
itemIDs and spellIDs very rarely (if ever) change, and if they did it would be with a patch.
|
Quote:
Lua Code:
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. |
All times are GMT -6. The time now is 06:13 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI