explain item qualities better
Kevin Gilbert [08-26-16 - 15:23]
explain item qualities better
diff --git a/ArtifactMenu.lua b/ArtifactMenu.lua
index 4be4b4c..b418bb5 100644
--- a/ArtifactMenu.lua
+++ b/ArtifactMenu.lua
@@ -11,14 +11,23 @@ local function openOffhandSockets()
end
function SlashCmdList.ARTIFACTMENU(msg, editBox)
- local ARTIFACT = 6; -- http://wowprogramming.com/docs/api_types#itemQuality
+ -- http://wowprogramming.com/docs/api_types#itemQuality
+ local QUALITY = {}
+ QUALITY.POOR = 0;
+ QUALITY.COMMON = 1;
+ QUALITY.UNCOMMON = 2;
+ QUALITY.RARE = 3;
+ QUALITY.EPIC = 4;
+ QUALITY.LEGENDARY = 5;
+ QUALITY.ARTIFACT = 6;
+ QUALITY.HEIRLOOM = 7;
local equippedWeapon = GetInventoryItemID("player", GetInventorySlotInfo("MainHandSlot"));
if equippedWeapon == nil then
print("You do not have any weapons equipped.");
return
end
name, link, quality, iLvl, reqLvl, class, subclass, maxStack, equipSlot, texture, vendorSellPrice = GetItemInfo(equippedWeapon);
- if quality == ARTIFACT then
+ if quality == QUALITY["ARTIFACT"] then
openWeaponSockets();
else
print("You do not have an Artifact Weapon equipped yet.");