ItemType

From Wowpedia
Jump to: navigation, search

GetItemInfo

Every item returned from GetItemInfo() has a type and subtype. It's preferable to use the item classID (since they match the LE_ITEM_CLASS enums) instead of the localized itemType.

itemType, itemSubType, _, _, _, _, classID, subclassID = select(6, GetItemInfo(itemID))
6. itemType 
string - The localized type of the item.
7. itemSubType 
string - The localized sub-type of the item.
12. classID 
number - The class ID of the item.
13. subclassID 
number - The subclass ID of the item.

Item Type

Enum classID itemType Description
LE_ITEM_CLASS_CONSUMABLE
0
Consumable
LE_ITEM_CLASS_CONTAINER
1
Container
LE_ITEM_CLASS_WEAPON
2
Weapon
LE_ITEM_CLASS_GEM
3
Gem
LE_ITEM_CLASS_ARMOR
4
Armor
LE_ITEM_CLASS_REAGENT
5
Reagent Obsolete
LE_ITEM_CLASS_PROJECTILE
6
Projectile Obsolete
LE_ITEM_CLASS_TRADEGOODS
7
Tradeskill
LE_ITEM_CLASS_ITEM_ENHANCEMENT
8
Item Enhancement
LE_ITEM_CLASS_RECIPE
9
Recipe
10
Money(OBSOLETE)
LE_ITEM_CLASS_QUIVER
11
Quiver Obsolete
LE_ITEM_CLASS_QUESTITEM
12
Quest
LE_ITEM_CLASS_KEY
13
Key Obsolete
14
Permanent(OBSOLETE)
LE_ITEM_CLASS_MISCELLANEOUS
15
Miscellaneous
LE_ITEM_CLASS_GLYPH
16
Glyph
LE_ITEM_CLASS_BATTLEPET
17
Battle Pets
LE_ITEM_CLASS_WOW_TOKEN
18
WoW Token

Item Subtype

Note
Note: All (localized) type names are spelled verbatim.


0: Consumable

subclassID itemSubType Description
0
Explosives and Devices
1
Potion
2
Elixir
3
Flask
4
Scroll (OBSOLETE)
5
Food & Drink
6
Item Enhancement (OBSOLETE)
7
Bandage
8
Other
9
Vantus Runes

1: Container

subclassID itemSubType Description
0
Bag
1
Soul Bag Classic
2
Herb Bag
3
Enchanting Bag
4
Engineering Bag
5
Gem Bag
6
Mining Bag
7
Leatherworking Bag
8
Inscription Bag
9
Tackle Box
10
Cooking Bag

2: Weapon

Enum subclassID itemSubType Description
LE_ITEM_WEAPON_AXE1H
0
One-Handed Axes
LE_ITEM_WEAPON_AXE2H
1
Two-Handed Axes
LE_ITEM_WEAPON_BOWS
2
Bows
LE_ITEM_WEAPON_GUNS
3
Guns
LE_ITEM_WEAPON_MACE1H
4
One-Handed Maces
LE_ITEM_WEAPON_MACE2H
5
Two-Handed Maces
LE_ITEM_WEAPON_POLEARM
6
Polearms
LE_ITEM_WEAPON_SWORD1H
7
One-Handed Swords
LE_ITEM_WEAPON_SWORD2H
8
Two-Handed Swords
LE_ITEM_WEAPON_WARGLAIVE
9
Warglaives
LE_ITEM_WEAPON_STAFF
10
Staves
LE_ITEM_WEAPON_BEARCLAW
11
Bear Claws
LE_ITEM_WEAPON_CATCLAW
12
CatClaws
LE_ITEM_WEAPON_UNARMED
13
Fist Weapons
LE_ITEM_WEAPON_GENERIC
14
Miscellaneous
LE_ITEM_WEAPON_DAGGER
15
Daggers
LE_ITEM_WEAPON_THROWN
16
Thrown Classic
17
Spears
LE_ITEM_WEAPON_CROSSBOW
18
Crossbows
LE_ITEM_WEAPON_WAND
19
Wands
LE_ITEM_WEAPON_FISHINGPOLE
20
Fishing Poles

3: Gem

Enum subclassID itemSubType Description
LE_ITEM_GEM_INTELLECT
0
Intellect
LE_ITEM_GEM_AGILITY
1
Agility
LE_ITEM_GEM_STRENGTH
2
Strength
LE_ITEM_GEM_STAMINA
3
Stamina
LE_ITEM_GEM_SPIRIT
4
Spirit
LE_ITEM_GEM_CRITICALSTRIKE
5
Critical Strike
LE_ITEM_GEM_MASTERY
6
Mastery
LE_ITEM_GEM_HASTE
7
Haste
LE_ITEM_GEM_VERSATILITY
8
Versatility
9
Other
LE_ITEM_GEM_MULTIPLESTATS
10
Multiple Stats
LE_ITEM_GEM_ARTIFACTRELIC
11
Artifact Relic

4: Armor

Enum subclassID itemSubType Description
LE_ITEM_ARMOR_GENERIC
0
Miscellaneous Includes Spellstones, Firestones, Trinkets, Rings and Necks
LE_ITEM_ARMOR_CLOTH
1
Cloth
LE_ITEM_ARMOR_LEATHER
2
Leather
LE_ITEM_ARMOR_MAIL
3
Mail
LE_ITEM_ARMOR_PLATE
4
Plate
LE_ITEM_ARMOR_COSMETIC
5
Cosmetic
LE_ITEM_ARMOR_SHIELD
6
Shields
LE_ITEM_ARMOR_LIBRAM
7
Librams Classic
LE_ITEM_ARMOR_IDOL
8
Idols Classic
LE_ITEM_ARMOR_TOTEM
9
Totems Classic
LE_ITEM_ARMOR_SIGIL
10
Sigils Classic
LE_ITEM_ARMOR_RELIC
11
Relic

5: Reagent - For crafting reagents see 7: Tradeskill. For spell reagents see 15: Miscellaneous.

subclassID itemSubType Description
0
Reagent
1
Keystone

6: Projectile

subclassID itemSubType Description
0
Wand(OBSOLETE)
1
Bolt(OBSOLETE)
2
Arrow
3
Bullet
4
Thrown(OBSOLETE)

7: Tradeskill

subclassID itemSubType Description
0
Trade Goods (OBSOLETE)
1
Parts
2
Explosives (OBSOLETE)
3
Devices (OBSOLETE)
4
Jewelcrafting
5
Cloth
6
Leather
7
Metal & Stone
8
Cooking
9
Herb
10
Elemental
11
Other
12
Enchanting
13
Materials (OBSOLETE)
14
Item Enchantment (OBSOLETE)
15
Weapon Enchantment - Obsolete
16
Inscription
17
Explosives and Devices (OBSOLETE)

8: Item Enhancement

subclassID itemSubType Description
0
Head
1
Neck
2
Shoulder
3
Cloak
4
Chest
5
Wrist
6
Hands
7
Waist
8
Legs
9
Feet
10
Finger
11
Weapon One-handed weapons
12
Two-Handed Weapon
13
Shield/Off-hand
14
Misc

9: Recipe

Enum subclassID itemSubType Description
LE_ITEM_RECIPE_BOOK
0
Book
LE_ITEM_RECIPE_LEATHERWORKING
1
Leatherworking
LE_ITEM_RECIPE_TAILORING
2
Tailoring
LE_ITEM_RECIPE_ENGINEERING
3
Engineering
LE_ITEM_RECIPE_BLACKSMITHING
4
Blacksmithing
LE_ITEM_RECIPE_COOKING
5
Cooking
LE_ITEM_RECIPE_ALCHEMY
6
Alchemy
LE_ITEM_RECIPE_FIRST_AID
7
First Aid
LE_ITEM_RECIPE_ENCHANTING
8
Enchanting
LE_ITEM_RECIPE_FISHING
9
Fishing
LE_ITEM_RECIPE_JEWELCRAFTING
10
Jewelcrafting
LE_ITEM_RECIPE_INSCRIPTION
11
Inscription

10: Money(OBSOLETE)

subclassID itemSubType Description
0
Money(OBSOLETE)

11: Quiver

subclassID itemSubType Description
0
Quiver(OBSOLETE)
1
Bolt(OBSOLETE)
2
Quiver
3
Ammo Pouch

12: Quest

subclassID itemSubType Description
0
Quest

13: Key

subclassID itemSubType Description
0
Key
1
Lockpick

14: Permanent(OBSOLETE)

subclassID itemSubType Description
0
Permanent

15: Miscellaneous

Enum subclassID itemSubType Description
LE_ITEM_MISCELLANEOUS_JUNK
0
Junk
LE_ITEM_MISCELLANEOUS_REAGENT
1
Reagent Mainly spell reagents. For crafting reagents see 7: Tradeskill.
LE_ITEM_MISCELLANEOUS_COMPANION_PET
2
Companion Pets
LE_ITEM_MISCELLANEOUS_HOLIDAY
3
Holiday
LE_ITEM_MISCELLANEOUS_OTHER
4
Other
LE_ITEM_MISCELLANEOUS_MOUNT
5
Mount
LE_ITEM_MISCELLANEOUS_MOUNT_EQUIPMENT
6
Mount Equipment

16: Glyph

subclassID itemSubType Description
1
Warrior
2
Paladin
3
Hunter
4
Rogue
5
Priest
6
Death Knight
7
Shaman
8
Mage
9
Warlock
10
Monk
11
Druid
12
Demon Hunter

17: Battle Pets

subclassID itemSubType Description
0
Humanoid
1
Dragonkin
2
Flying
3
Undead
4
Critter
5
Magic
6
Elemental
7
Beast
8
Aquatic
9
Mechanical

18: WoW Token

subclassID itemSubType Description
0
WoW Token

See also