public WoWObject(uint bAddress, WoWConnection wowConnection) { this.BaseAddress = bAddress; this.Guid = wowConnection.Connection.ReadUInt64(this.BaseAddress + MemoryOffsets.ObjectManagerLocalGUID); ulong temp = this.guid >> 52; switch ((this.guid >> 52) & 0xF0F) { case 0x000: this.UnitType = WoWUnitType.Player; break; case 0xF00: this.UnitType = WoWUnitType.Spell; break; case 0xF03: this.UnitType = WoWUnitType.NPC; break; case 0xF01: this.UnitType = WoWUnitType.WorldObject; break; case 0xF04: this.UnitType = WoWUnitType.PermanentPet; break; default: this.UnitType = WoWUnitType.Unknown; break; } }
public WoWObject(WoWObject other) { this.BaseAddress = other.BaseAddress; this.Guid = other.Guid; this.UnitType = other.UnitType; }