Quantcast
Knowing if an equippable item is "valid" for the player character's class - WoWInterface
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
08-15-18, 03:55 PM   #1
Ammako
A Frostmaul Preserver
AddOn Author - Click to view addons
Join Date: Jun 2016
Posts: 256
Knowing if an equippable item is "valid" for the player character's class

I'm writing a thing to replace the non-functional IsContainerItemAnUpgrade(), because I can.

The core logic for my code is functional, but it doesn't check if an item is of the right armor type, or if it's even equipable at all by the player character's class. There doesn't seem to be an API function to directly check this. Is there an "agreed upon" good way of doing this?

I have an idea in mind involving hardcoded arrays and for loops, to check if the current item is valid for the player character's class, but I'm probably missing something and this is probably not the best way to do it. I'd rather not have to reinvent the wheel if somebody else already has a solution, anyway.
  Reply With Quote
 

WoWInterface » Developer Discussions » Lua/XML Help » Knowing if an equippable item is "valid" for the player character's class

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off