// ugly hack public static ObjectTypeId GetTypeId(WowGuidType type) { switch (type) { case WowGuidType.Corpse: return(ObjectTypeId.Corpse); case WowGuidType.DynamicObject: return(ObjectTypeId.DynamicObject); case WowGuidType.TransportMo: case WowGuidType.Transport: case WowGuidType.GameObject: return(ObjectTypeId.GameObject); case WowGuidType.Item: return(ObjectTypeId.Item); case WowGuidType.Player: return(ObjectTypeId.Player); case WowGuidType.Pet: case WowGuidType.Creature: case WowGuidType.Vehicle: return(ObjectTypeId.Unit); default: return(ObjectTypeId.Object); } }
public HighInfo(WowGuidType type, WowGuidKind kind, int mask, int value, int defaultValue) { this.Type = type; this.Kind = kind; this.Mask = mask; this.Value = value; this.DefaultValue = defaultValue; }
public WowGuid(WowGuidType type, uint entry, ulong counter) { m_raw = 0; var info = s_typeValuePairs.FirstOrDefault(_ => _.Type == type); if (info == null) { throw new ArgumentException("type"); } this.High = info.DefaultValue; this.Entry = entry; this.Counter = counter; }
// ugly hack public static ObjectTypeId GetTypeId(WowGuidType type) { switch (type) { case WowGuidType.Corpse: return ObjectTypeId.Corpse; case WowGuidType.DynamicObject: return ObjectTypeId.DynamicObject; case WowGuidType.TransportMo: case WowGuidType.Transport: case WowGuidType.GameObject: return ObjectTypeId.GameObject; case WowGuidType.Item: return ObjectTypeId.Item; case WowGuidType.Player: return ObjectTypeId.Player; case WowGuidType.Pet: case WowGuidType.Creature: case WowGuidType.Vehicle: return ObjectTypeId.Unit; default: return ObjectTypeId.Object; } }
public WowGuid(WowGuidType type, ulong counter) : this(type, 0, counter) { }