Originally Posted by
amadmonk
Also if you're OOP you can just read the appropriate DBC file. That's what I was doing with my packet reader. Probably the in-proc DBC is faster tho.
Pretty sure stuff like item names are not stored in the dbc's. The client queries the server on items it's never seen before, server responds with the large struct apoc mentioned (See below), which is then cached in WDB's for future reference (by version).
Here's the structure according to wcell:
Code:
public class ItemTemplate
{
public string Name { get; set; }
public uint Id { get; set; }
public ItemId ItemId { get; set; }
public ItemClass Class { get; set; }
public ItemSubClass SubClass { get; set; }
public uint DisplayId { get; set; }
public ItemQuality Quality { get; set; }
public ItemFlags Flags { get; set; }
public uint BuyPrice { get; set; }
public uint SellPrice { get; set; }
public InventorySlotType InventorySlotType { get; set; }
public ClassMask RequiredClassMask { get; set; }
public RaceMask RequiredRaceMask { get; set; }
public uint Level { get; set; }
public uint RequiredLevel { get; set; }
public SkillId RequiredSkillId { get; set; }
public uint RequiredSkillValue { get; set; }
public SpellId RequiredProfessionId { get; set; }
public uint RequiredPvPRank { get; set; }
public uint UnknownRank { get; set; }
public FactionId RequiredFactionId { get; set; }
public StandingLevel RequiredFactionStanding { get; set; }
public uint UniqueCount { get; set; }
/// <summary>
/// The size of a stack of this item.
/// </summary>
public uint MaxAmount { get; set; }
public int ContainerSlots { get; set; }
public StatModifier[] Mods { get; set; }
public DamageInfo[] Damages { get; set; }
public int[] Resistances { get; set; }
public int AttackTime { get; set; }
public ItemProjectileType ProjectileType { get; set; }
public float RangeModifier { get; set; }
public ItemBondType BondType { get; set; }
public string Description { get; set; }
public uint PageTextId { get; set; }
public uint PageCount { get; set; }
public PageMaterial PageMaterial { get; set; }
/// <summary>
/// The Id of the Quest that will be started
/// when this Item is used.
/// </summary>
public uint QuestId { get; set; }
public uint LockId { get; set; }
public Material Material { get; set; }
public SheathType SheathType { get; set; }
public uint RandomPropertiesId { get; set; }
public uint RandomSuffixId { get; set; }
public uint BlockValue { get; set; }
public ItemSetId SetId { get; set; }
public int MaxDurability { get; set; }
public ZoneId ZoneId { get; set; }
public MapId MapId { get; set; }
public ItemBagFamilyMask BagFamily { get; set; }
public TotemCategory TotemCategory { get; set; }
public GemSocketInfo[] Sockets { get; set; }
/// <summary>
///
/// </summary>
public uint SocketBonusEnchantId { get; set; }
public ItemEnchantmentEntry SocketBonusEnchant { get; set; }
public uint GemPropertiesId { get; set; }
public GemProperties GemProperties { get; set; }
public int RequiredDisenchantingLevel { get; set; }
public float ArmorModifier { get; set; }
public int Duration { get; set; }
public uint[] Spells { get; set; }
#region Custom
public InventorySlotMask InventorySlotMask { get; set; }
public uint RandomSuffixFactor { get; set; }
public uint RequiredSkill { get; set; }
public ItemSubClassMask SubClassMask { get; set; }
/// <summary>
/// Spell to be casted when using this item
/// </summary>
public uint UseSpell { get; set; }
/// <summary>
/// Spell that is casted once and then consumes this Item (usually teaching formulars, patterns, designs etc)
/// </summary>
public uint TeachSpell { get; set; }
/// <summary>
/// Spell to be casted when equipping
/// </summary>
public uint EquipSpell { get; set; }
/// <summary>
/// Spell to be casted when being hit
/// </summary>
public uint HitSpell { get; set; }
/// <summary>
/// Spell to be casted when using Soulstone
/// </summary>
public uint SoulstoneSpell { get; set; }
/// <summary>
/// The ItemSet to which this Item belongs (if any)
/// </summary>
public uint ItemSet { get; set; }
public uint RequiredFaction { get; set; }
public uint RequiredProfession { get; set; }
/// <summary>
/// EquipmentSlots to which this item can be equipped
/// </summary>
public EquipmentSlot[] EquipmentSlots { get; set; }
/// <summary>
/// whether this is ammo
/// </summary>
public bool IsAmmo { get; set; }
/// <summary>
/// whether this is a bag (includes quivers)
/// </summary>
public bool IsBag { get; set; }
/// <summary>
/// whether this is a container (includes chests, clams, bags, quivers, etc.)
/// </summary>
public bool IsContainer { get; set; }
/// <summary>
/// whether this is a key
/// </summary>
public bool IsKey { get; set; }
/// <summary>
/// whether this can be stacked
/// </summary>
public bool IsStackable { get; set; }
/// <summary>
/// whether this is a weapon
/// </summary>
public bool IsWeapon { get; set; }
/// <summary>
/// whether this is a ranged weapon
/// </summary>
public bool IsRangedWeapon { get; set; }
public bool IsThrowable { get; set; }
/// <summary>
/// whether this is a 2h weapon
/// </summary>
public bool IsTwoHandWeapon { get; set; }
/// <summary>
/// whether this teleports one home when using it
/// </summary>
public bool IsHearthStone { get; set; }
/// <summary>
/// The skill needed for this item, for armors, weapons, shields etc
/// </summary>
public SkillId ItemProfession { get; set; }
/// <summary>
/// whether this Item is an equippable Item and not a bag
/// </summary>
public bool IsInventory { get; set; }
/// <summary>
/// The Quest for which this Item needs to be collected
/// </summary>
public uint[] CollectQuests { get; set; }
/// <summary>
/// The Quest that will be started by this Item
/// </summary>
public uint StartQuest { get; set; }
/// <summary>
/// Whether this ItemTemplate has any sockets
/// </summary>
public bool HasSockets { get; set; }
public bool ConsumesAmount;
#endregion
}