2 * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/>
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 #ifndef _ITEMPROTOTYPE_H
20 #define _ITEMPROTOTYPE_H
29 ITEM_MOD_STRENGTH
= 4,
30 ITEM_MOD_INTELLECT
= 5,
33 ITEM_MOD_DEFENSE_SKILL_RATING
= 12,
34 ITEM_MOD_DODGE_RATING
= 13,
35 ITEM_MOD_PARRY_RATING
= 14,
36 ITEM_MOD_BLOCK_RATING
= 15,
37 ITEM_MOD_HIT_MELEE_RATING
= 16,
38 ITEM_MOD_HIT_RANGED_RATING
= 17,
39 ITEM_MOD_HIT_SPELL_RATING
= 18,
40 ITEM_MOD_CRIT_MELEE_RATING
= 19,
41 ITEM_MOD_CRIT_RANGED_RATING
= 20,
42 ITEM_MOD_CRIT_SPELL_RATING
= 21,
43 ITEM_MOD_HIT_TAKEN_MELEE_RATING
= 22,
44 ITEM_MOD_HIT_TAKEN_RANGED_RATING
= 23,
45 ITEM_MOD_HIT_TAKEN_SPELL_RATING
= 24,
46 ITEM_MOD_CRIT_TAKEN_MELEE_RATING
= 25,
47 ITEM_MOD_CRIT_TAKEN_RANGED_RATING
= 26,
48 ITEM_MOD_CRIT_TAKEN_SPELL_RATING
= 27,
49 ITEM_MOD_HASTE_MELEE_RATING
= 28,
50 ITEM_MOD_HASTE_RANGED_RATING
= 29,
51 ITEM_MOD_HASTE_SPELL_RATING
= 30,
52 ITEM_MOD_HIT_RATING
= 31,
53 ITEM_MOD_CRIT_RATING
= 32,
54 ITEM_MOD_HIT_TAKEN_RATING
= 33,
55 ITEM_MOD_CRIT_TAKEN_RATING
= 34,
56 ITEM_MOD_RESILIENCE_RATING
= 35,
57 ITEM_MOD_HASTE_RATING
= 36,
58 ITEM_MOD_EXPERTISE_RATING
= 37,
59 ITEM_MOD_ATTACK_POWER
= 38,
60 ITEM_MOD_RANGED_ATTACK_POWER
= 39,
61 ITEM_MOD_FERAL_ATTACK_POWER
= 40,
62 ITEM_MOD_SPELL_HEALING_DONE
= 41, // deprecated
63 ITEM_MOD_SPELL_DAMAGE_DONE
= 42, // deprecated
64 ITEM_MOD_MANA_REGENERATION
= 43,
65 ITEM_MOD_ARMOR_PENETRATION_RATING
= 44,
66 ITEM_MOD_SPELL_POWER
= 45,
67 ITEM_MOD_HEALTH_REGEN
= 46,
68 ITEM_MOD_SPELL_PENETRATION
= 47,
69 ITEM_MOD_BLOCK_VALUE
= 48
72 #define MAX_ITEM_MOD 49
74 enum ItemSpelltriggerType
76 ITEM_SPELLTRIGGER_ON_USE
= 0, // use after equip cooldown
77 ITEM_SPELLTRIGGER_ON_EQUIP
= 1,
78 ITEM_SPELLTRIGGER_CHANCE_ON_HIT
= 2,
79 ITEM_SPELLTRIGGER_SOULSTONE
= 4,
81 * ItemSpelltriggerType 5 might have changed on 2.4.3/3.0.3: Such auras
82 * will be applied on item pickup and removed on item loss - maybe on the
83 * other hand the item is destroyed if the aura is removed ("removed on
84 * death" of spell 57348 makes me think so)
86 ITEM_SPELLTRIGGER_ON_NO_DELAY_USE
= 5, // no equip cooldown
87 ITEM_SPELLTRIGGER_LEARN_SPELL_ID
= 6 // used in item_template.spell_2 with spell_id with SPELL_GENERIC_LEARN in spell_1
90 #define MAX_ITEM_SPELLTRIGGER 7
95 BIND_WHEN_PICKED_UP
= 1,
96 BIND_WHEN_EQUIPED
= 2,
99 BIND_QUEST_ITEM1
= 5 // not used in game
102 #define MAX_BIND_TYPE 6
104 // masks for ITEM_FIELD_FLAGS field
107 ITEM_FLAGS_BINDED
= 0x00000001, // set in game at binding, not set in template
108 ITEM_FLAGS_CONJURED
= 0x00000002,
109 ITEM_FLAGS_OPENABLE
= 0x00000004,
110 ITEM_FLAGS_WRAPPED
= 0x00000008,
111 ITEM_FLAGS_HEROIC
= 0x00000008, // weird...
112 ITEM_FLAGS_BROKEN
= 0x00000010, // appears red icon (like when item durability==0)
113 ITEM_FLAGS_TOTEM
= 0x00000020, // ?
114 ITEM_FLAGS_USABLE
= 0x00000040, // ?
115 ITEM_FLAGS_NO_EQUIP_COOLDOWN
= 0x00000080, // ?
116 ITEM_FLAGS_WRAPPER
= 0x00000200, // used or not used wrapper
117 ITEM_FLAGS_IGNORE_BAG_SPACE
= 0x00000400, // ignore bag space at new item creation?
118 ITEM_FLAGS_PARTY_LOOT
= 0x00000800, // determines if item is party loot or not
119 ITEM_FLAGS_REFUNDABLE
= 0x00001000, // item cost can be refunded within 2 hours after purchase
120 ITEM_FLAGS_CHARTER
= 0x00002000, // arena/guild charter
121 ITEM_FLAGS_REFUNDABLE_2
= 0x00008000, // ?
122 ITEM_FLAGS_PROSPECTABLE
= 0x00040000,
123 ITEM_FLAGS_UNIQUE_EQUIPPED
= 0x00080000,
124 ITEM_FLAGS_USEABLE_IN_ARENA
= 0x00200000,
125 ITEM_FLAGS_THROWABLE
= 0x00400000, // not used in game for check trow possibility, only for item in game tooltip
126 ITEM_FLAGS_SPECIALUSE
= 0x00800000, // last used flag in 2.3.0
127 ITEM_FLAGS_BOA
= 0x08000000, // bind on account (set in template for items that can binded in like way)
128 ITEM_FLAGS_ENCHANT_SCROLL
= 0x10000000, // for enchant scrolls
129 ITEM_FLAGS_MILLABLE
= 0x20000000,
130 ITEM_FLAGS_BOP_TRADEABLE
= 0x80000000
135 BAG_FAMILY_MASK_NONE
= 0x00000000,
136 BAG_FAMILY_MASK_ARROWS
= 0x00000001,
137 BAG_FAMILY_MASK_BULLETS
= 0x00000002,
138 BAG_FAMILY_MASK_SOUL_SHARDS
= 0x00000004,
139 BAG_FAMILY_MASK_LEATHERWORKING_SUPP
= 0x00000008,
140 BAG_FAMILY_MASK_INSCRIPTION_SUPP
= 0x00000010,
141 BAG_FAMILY_MASK_HERBS
= 0x00000020,
142 BAG_FAMILY_MASK_ENCHANTING_SUPP
= 0x00000040,
143 BAG_FAMILY_MASK_ENGINEERING_SUPP
= 0x00000080,
144 BAG_FAMILY_MASK_KEYS
= 0x00000100,
145 BAG_FAMILY_MASK_GEMS
= 0x00000200,
146 BAG_FAMILY_MASK_MINING_SUPP
= 0x00000400,
147 BAG_FAMILY_MASK_SOULBOUND_EQUIPMENT
= 0x00000800,
148 BAG_FAMILY_MASK_VANITY_PETS
= 0x00001000,
149 BAG_FAMILY_MASK_CURRENCY_TOKENS
= 0x00002000,
150 BAG_FAMILY_MASK_QUEST_ITEMS
= 0x00004000
155 SOCKET_COLOR_META
= 1,
156 SOCKET_COLOR_RED
= 2,
157 SOCKET_COLOR_YELLOW
= 4,
158 SOCKET_COLOR_BLUE
= 8
161 #define SOCKET_COLOR_ALL (SOCKET_COLOR_META | SOCKET_COLOR_RED | SOCKET_COLOR_YELLOW | SOCKET_COLOR_BLUE)
165 INVTYPE_NON_EQUIP
= 0,
168 INVTYPE_SHOULDERS
= 3,
177 INVTYPE_TRINKET
= 12,
182 INVTYPE_2HWEAPON
= 17,
186 INVTYPE_WEAPONMAINHAND
= 21,
187 INVTYPE_WEAPONOFFHAND
= 22,
188 INVTYPE_HOLDABLE
= 23,
191 INVTYPE_RANGEDRIGHT
= 26,
196 #define MAX_INVTYPE 29
200 ITEM_CLASS_CONSUMABLE
= 0,
201 ITEM_CLASS_CONTAINER
= 1,
202 ITEM_CLASS_WEAPON
= 2,
204 ITEM_CLASS_ARMOR
= 4,
205 ITEM_CLASS_REAGENT
= 5,
206 ITEM_CLASS_PROJECTILE
= 6,
207 ITEM_CLASS_TRADE_GOODS
= 7,
208 ITEM_CLASS_GENERIC
= 8,
209 ITEM_CLASS_RECIPE
= 9,
210 ITEM_CLASS_MONEY
= 10,
211 ITEM_CLASS_QUIVER
= 11,
212 ITEM_CLASS_QUEST
= 12,
214 ITEM_CLASS_PERMANENT
= 14,
215 ITEM_CLASS_MISC
= 15,
216 ITEM_CLASS_GLYPH
= 16
219 #define MAX_ITEM_CLASS 17
221 enum ItemSubclassConsumable
223 ITEM_SUBCLASS_CONSUMABLE
= 0,
224 ITEM_SUBCLASS_POTION
= 1,
225 ITEM_SUBCLASS_ELIXIR
= 2,
226 ITEM_SUBCLASS_FLASK
= 3,
227 ITEM_SUBCLASS_SCROLL
= 4,
228 ITEM_SUBCLASS_FOOD
= 5,
229 ITEM_SUBCLASS_ITEM_ENHANCEMENT
= 6,
230 ITEM_SUBCLASS_BANDAGE
= 7,
231 ITEM_SUBCLASS_CONSUMABLE_OTHER
= 8
234 #define MAX_ITEM_SUBCLASS_CONSUMABLE 9
236 enum ItemSubclassContainer
238 ITEM_SUBCLASS_CONTAINER
= 0,
239 ITEM_SUBCLASS_SOUL_CONTAINER
= 1,
240 ITEM_SUBCLASS_HERB_CONTAINER
= 2,
241 ITEM_SUBCLASS_ENCHANTING_CONTAINER
= 3,
242 ITEM_SUBCLASS_ENGINEERING_CONTAINER
= 4,
243 ITEM_SUBCLASS_GEM_CONTAINER
= 5,
244 ITEM_SUBCLASS_MINING_CONTAINER
= 6,
245 ITEM_SUBCLASS_LEATHERWORKING_CONTAINER
= 7,
246 ITEM_SUBCLASS_INSCRIPTION_CONTAINER
= 8
249 #define MAX_ITEM_SUBCLASS_CONTAINER 9
251 enum ItemSubclassWeapon
253 ITEM_SUBCLASS_WEAPON_AXE
= 0,
254 ITEM_SUBCLASS_WEAPON_AXE2
= 1,
255 ITEM_SUBCLASS_WEAPON_BOW
= 2,
256 ITEM_SUBCLASS_WEAPON_GUN
= 3,
257 ITEM_SUBCLASS_WEAPON_MACE
= 4,
258 ITEM_SUBCLASS_WEAPON_MACE2
= 5,
259 ITEM_SUBCLASS_WEAPON_POLEARM
= 6,
260 ITEM_SUBCLASS_WEAPON_SWORD
= 7,
261 ITEM_SUBCLASS_WEAPON_SWORD2
= 8,
262 ITEM_SUBCLASS_WEAPON_obsolete
= 9,
263 ITEM_SUBCLASS_WEAPON_STAFF
= 10,
264 ITEM_SUBCLASS_WEAPON_EXOTIC
= 11,
265 ITEM_SUBCLASS_WEAPON_EXOTIC2
= 12,
266 ITEM_SUBCLASS_WEAPON_FIST
= 13,
267 ITEM_SUBCLASS_WEAPON_MISC
= 14,
268 ITEM_SUBCLASS_WEAPON_DAGGER
= 15,
269 ITEM_SUBCLASS_WEAPON_THROWN
= 16,
270 ITEM_SUBCLASS_WEAPON_SPEAR
= 17,
271 ITEM_SUBCLASS_WEAPON_CROSSBOW
= 18,
272 ITEM_SUBCLASS_WEAPON_WAND
= 19,
273 ITEM_SUBCLASS_WEAPON_FISHING_POLE
= 20
276 #define MAX_ITEM_SUBCLASS_WEAPON 21
280 ITEM_SUBCLASS_GEM_RED
= 0,
281 ITEM_SUBCLASS_GEM_BLUE
= 1,
282 ITEM_SUBCLASS_GEM_YELLOW
= 2,
283 ITEM_SUBCLASS_GEM_PURPLE
= 3,
284 ITEM_SUBCLASS_GEM_GREEN
= 4,
285 ITEM_SUBCLASS_GEM_ORANGE
= 5,
286 ITEM_SUBCLASS_GEM_META
= 6,
287 ITEM_SUBCLASS_GEM_SIMPLE
= 7,
288 ITEM_SUBCLASS_GEM_PRISMATIC
= 8
291 #define MAX_ITEM_SUBCLASS_GEM 9
293 enum ItemSubclassArmor
295 ITEM_SUBCLASS_ARMOR_MISC
= 0,
296 ITEM_SUBCLASS_ARMOR_CLOTH
= 1,
297 ITEM_SUBCLASS_ARMOR_LEATHER
= 2,
298 ITEM_SUBCLASS_ARMOR_MAIL
= 3,
299 ITEM_SUBCLASS_ARMOR_PLATE
= 4,
300 ITEM_SUBCLASS_ARMOR_BUCKLER
= 5,
301 ITEM_SUBCLASS_ARMOR_SHIELD
= 6,
302 ITEM_SUBCLASS_ARMOR_LIBRAM
= 7,
303 ITEM_SUBCLASS_ARMOR_IDOL
= 8,
304 ITEM_SUBCLASS_ARMOR_TOTEM
= 9,
305 ITEM_SUBCLASS_ARMOR_SIGIL
= 10
308 #define MAX_ITEM_SUBCLASS_ARMOR 11
310 enum ItemSubclassReagent
312 ITEM_SUBCLASS_REAGENT
= 0
315 #define MAX_ITEM_SUBCLASS_REAGENT 1
317 enum ItemSubclassProjectile
319 ITEM_SUBCLASS_WAND
= 0, // ABS
320 ITEM_SUBCLASS_BOLT
= 1, // ABS
321 ITEM_SUBCLASS_ARROW
= 2,
322 ITEM_SUBCLASS_BULLET
= 3,
323 ITEM_SUBCLASS_THROWN
= 4 // ABS
326 #define MAX_ITEM_SUBCLASS_PROJECTILE 5
328 enum ItemSubclassTradeGoods
330 ITEM_SUBCLASS_TRADE_GOODS
= 0,
331 ITEM_SUBCLASS_PARTS
= 1,
332 ITEM_SUBCLASS_EXPLOSIVES
= 2,
333 ITEM_SUBCLASS_DEVICES
= 3,
334 ITEM_SUBCLASS_JEWELCRAFTING
= 4,
335 ITEM_SUBCLASS_CLOTH
= 5,
336 ITEM_SUBCLASS_LEATHER
= 6,
337 ITEM_SUBCLASS_METAL_STONE
= 7,
338 ITEM_SUBCLASS_MEAT
= 8,
339 ITEM_SUBCLASS_HERB
= 9,
340 ITEM_SUBCLASS_ELEMENTAL
= 10,
341 ITEM_SUBCLASS_TRADE_GOODS_OTHER
= 11,
342 ITEM_SUBCLASS_ENCHANTING
= 12,
343 ITEM_SUBCLASS_MATERIAL
= 13,
344 ITEM_SUBCLASS_ARMOR_ENCHANTMENT
= 14,
345 ITEM_SUBCLASS_WEAPON_ENCHANTMENT
= 15
348 #define MAX_ITEM_SUBCLASS_TRADE_GOODS 16
350 enum ItemSubclassGeneric
352 ITEM_SUBCLASS_GENERIC
= 0
355 #define MAX_ITEM_SUBCLASS_GENERIC 1
357 enum ItemSubclassRecipe
359 ITEM_SUBCLASS_BOOK
= 0,
360 ITEM_SUBCLASS_LEATHERWORKING_PATTERN
= 1,
361 ITEM_SUBCLASS_TAILORING_PATTERN
= 2,
362 ITEM_SUBCLASS_ENGINEERING_SCHEMATIC
= 3,
363 ITEM_SUBCLASS_BLACKSMITHING
= 4,
364 ITEM_SUBCLASS_COOKING_RECIPE
= 5,
365 ITEM_SUBCLASS_ALCHEMY_RECIPE
= 6,
366 ITEM_SUBCLASS_FIRST_AID_MANUAL
= 7,
367 ITEM_SUBCLASS_ENCHANTING_FORMULA
= 8,
368 ITEM_SUBCLASS_FISHING_MANUAL
= 9,
369 ITEM_SUBCLASS_JEWELCRAFTING_RECIPE
= 10
372 #define MAX_ITEM_SUBCLASS_RECIPE 11
374 enum ItemSubclassMoney
376 ITEM_SUBCLASS_MONEY
= 0
379 #define MAX_ITEM_SUBCLASS_MONEY 1
381 enum ItemSubclassQuiver
383 ITEM_SUBCLASS_QUIVER0
= 0, // ABS
384 ITEM_SUBCLASS_QUIVER1
= 1, // ABS
385 ITEM_SUBCLASS_QUIVER
= 2,
386 ITEM_SUBCLASS_AMMO_POUCH
= 3
389 #define MAX_ITEM_SUBCLASS_QUIVER 4
391 enum ItemSubclassQuest
393 ITEM_SUBCLASS_QUEST
= 0
396 #define MAX_ITEM_SUBCLASS_QUEST 1
400 ITEM_SUBCLASS_KEY
= 0,
401 ITEM_SUBCLASS_LOCKPICK
= 1
404 #define MAX_ITEM_SUBCLASS_KEY 2
406 enum ItemSubclassPermanent
408 ITEM_SUBCLASS_PERMANENT
= 0
411 #define MAX_ITEM_SUBCLASS_PERMANENT 1
413 enum ItemSubclassJunk
415 ITEM_SUBCLASS_JUNK
= 0,
416 ITEM_SUBCLASS_JUNK_REAGENT
= 1,
417 ITEM_SUBCLASS_JUNK_PET
= 2,
418 ITEM_SUBCLASS_JUNK_HOLIDAY
= 3,
419 ITEM_SUBCLASS_JUNK_OTHER
= 4,
420 ITEM_SUBCLASS_JUNK_MOUNT
= 5
423 #define MAX_ITEM_SUBCLASS_JUNK 6
425 enum ItemSubclassGlyph
427 ITEM_SUBCLASS_GLYPH_WARRIOR
= 1,
428 ITEM_SUBCLASS_GLYPH_PALADIN
= 2,
429 ITEM_SUBCLASS_GLYPH_HUNTER
= 3,
430 ITEM_SUBCLASS_GLYPH_ROGUE
= 4,
431 ITEM_SUBCLASS_GLYPH_PRIEST
= 5,
432 ITEM_SUBCLASS_GLYPH_DEATH_KNIGHT
= 6,
433 ITEM_SUBCLASS_GLYPH_SHAMAN
= 7,
434 ITEM_SUBCLASS_GLYPH_MAGE
= 8,
435 ITEM_SUBCLASS_GLYPH_WARLOCK
= 9,
436 ITEM_SUBCLASS_GLYPH_DRUID
= 11
439 #define MAX_ITEM_SUBCLASS_GLYPH 12
441 const uint32 MaxItemSubclassValues
[MAX_ITEM_CLASS
] =
443 MAX_ITEM_SUBCLASS_CONSUMABLE
,
444 MAX_ITEM_SUBCLASS_CONTAINER
,
445 MAX_ITEM_SUBCLASS_WEAPON
,
446 MAX_ITEM_SUBCLASS_GEM
,
447 MAX_ITEM_SUBCLASS_ARMOR
,
448 MAX_ITEM_SUBCLASS_REAGENT
,
449 MAX_ITEM_SUBCLASS_PROJECTILE
,
450 MAX_ITEM_SUBCLASS_TRADE_GOODS
,
451 MAX_ITEM_SUBCLASS_GENERIC
,
452 MAX_ITEM_SUBCLASS_RECIPE
,
453 MAX_ITEM_SUBCLASS_MONEY
,
454 MAX_ITEM_SUBCLASS_QUIVER
,
455 MAX_ITEM_SUBCLASS_QUEST
,
456 MAX_ITEM_SUBCLASS_KEY
,
457 MAX_ITEM_SUBCLASS_PERMANENT
,
458 MAX_ITEM_SUBCLASS_JUNK
,
459 MAX_ITEM_SUBCLASS_GLYPH
462 inline uint8
ItemSubClassToDurabilityMultiplierId(uint32 ItemClass
, uint32 ItemSubClass
)
466 case ITEM_CLASS_WEAPON
: return ItemSubClass
;
467 case ITEM_CLASS_ARMOR
: return ItemSubClass
+ 21;
472 // GCC have alternative #pragma pack(N) syntax and old gcc version not support pack(push,N), also any gcc version not support it at some platform
473 #if defined( __GNUC__ )
483 uint32 DamageType
; // id from Resistances.dbc
493 uint32 SpellId
; // id from Spell.dbc
498 uint32 SpellCategory
; // id from SpellCategory.dbc
499 int32 SpellCategoryCooldown
;
508 #define MAX_ITEM_PROTO_DAMAGES 2 // changed in 3.1.0
509 #define MAX_ITEM_PROTO_SOCKETS 3
510 #define MAX_ITEM_PROTO_SPELLS 5
511 #define MAX_ITEM_PROTO_STATS 10
516 uint32 Class
; // id from ItemClass.dbc
517 uint32 SubClass
; // id from ItemSubClass.dbc
520 uint32 DisplayInfoID
; // id from ItemDisplayInfo.dbc
527 uint32 InventoryType
;
528 uint32 AllowableClass
;
529 uint32 AllowableRace
;
531 uint32 RequiredLevel
;
532 uint32 RequiredSkill
; // id from SkillLine.dbc
533 uint32 RequiredSkillRank
;
534 uint32 RequiredSpell
; // id from Spell.dbc
535 uint32 RequiredHonorRank
;
536 uint32 RequiredCityRank
;
537 uint32 RequiredReputationFaction
; // id from Faction.dbc
538 uint32 RequiredReputationRank
;
539 int32 MaxCount
; // <=0: no limit
540 int32 Stackable
; // 0: not allowed, -1: put in player coin info tab and don't limit stacking (so 1 slot)
541 uint32 ContainerSlots
;
543 _ItemStat ItemStat
[MAX_ITEM_PROTO_STATS
];
544 uint32 ScalingStatDistribution
; // id from ScalingStatDistribution.dbc
545 uint32 ScalingStatValue
; // mask for selecting column in ScalingStatValues.dbc
546 _Damage Damage
[MAX_ITEM_PROTO_DAMAGES
];
556 float RangedModRange
;
557 _Spell Spells
[MAX_ITEM_PROTO_SPELLS
];
563 uint32 StartQuest
; // id from QuestCache.wdb
565 int32 Material
; // id from Material.dbc
567 uint32 RandomProperty
; // id from ItemRandomProperties.dbc
568 uint32 RandomSuffix
; // id from ItemRandomSuffix.dbc
570 uint32 ItemSet
; // id from ItemSet.dbc
571 uint32 MaxDurability
;
572 uint32 Area
; // id from AreaTable.dbc
573 uint32 Map
; // id from Map.dbc
574 uint32 BagFamily
; // bit mask (1 << id from ItemBagFamily.dbc)
575 uint32 TotemCategory
; // id from TotemCategory.dbc
576 _Socket Socket
[MAX_ITEM_PROTO_SOCKETS
];
577 uint32 socketBonus
; // id from SpellItemEnchantment.dbc
578 uint32 GemProperties
; // id from GemProperties.dbc
579 uint32 RequiredDisenchantSkill
;
580 float ArmorDamageModifier
;
581 int32 Duration
; // negative = realtime, positive = ingame time
582 uint32 ItemLimitCategory
; // id from ItemLimitCategory.dbc
583 uint32 HolidayId
; // id from Holidays.dbc
591 bool CanChangeEquipStateInCombat() const
593 switch(InventoryType
)
597 case INVTYPE_HOLDABLE
:
603 case ITEM_CLASS_WEAPON
:
604 case ITEM_CLASS_PROJECTILE
:
611 uint32
GetMaxStackSize() const { return Stackable
> 0 ? uint32(Stackable
) : uint32(0x7FFFFFFF-1); }
618 for (int i
= 0; i
< MAX_ITEM_PROTO_DAMAGES
; ++i
)
619 temp
+=Damage
[i
].DamageMin
+ Damage
[i
].DamageMax
;
620 return temp
*500/Delay
;
623 int32
getFeralBonus(int32 extraDPS
= 0) const
625 // 0x02A5F3 - is mask for Melee weapon from ItemSubClassMask.dbc
626 if (Class
== ITEM_CLASS_WEAPON
&& (1<<SubClass
)&0x02A5F3)
628 int32 bonus
= int32((extraDPS
+ getDPS())*14.0f
) - 767;
636 bool IsPotion() const { return Class
==ITEM_CLASS_CONSUMABLE
&& SubClass
==ITEM_SUBCLASS_POTION
; }
637 bool IsConjuredConsumable() const { return Class
== ITEM_CLASS_CONSUMABLE
&& (Flags
& ITEM_FLAGS_CONJURED
); }
642 std::vector
<std::string
> Name
;
643 std::vector
<std::string
> Description
;
646 // GCC have alternative #pragma pack() syntax and old gcc version not support pack(pop), also any gcc version not support it at some platform
647 #if defined( __GNUC__ )