Code:
/*
This file is part of LazyBot - Copyright (C) 2011 Arutha
LazyBot is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
LazyBot is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with LazyBot. If not, see <http://www.gnu.org/licenses/>.
*/
#region
using System;
using System.Reflection;
#endregion
#if true
namespace LazyLib.Wow
{
[Obfuscation(Feature = "renaming", ApplyToMembers = true)]
public class PublicPointers
{
#region Globals enum
public enum Globals
{
PlayerName = 0x17EF7E0,
}
#endregion
#region InGame enum
public enum InGame
{
InGame = 0x16A2F5E,
InstanceSize = 0x16A3064,
}
#endregion
}
internal class Pointers
{
#region Nested type: ObjectManager
internal enum ObjectManager
{
//CurrentManager = Memory.Read<uint>(Memory.ReadRelative<uint>((uint) Pointers.ObjectManager.CurMgrPointer)
// + (uint) Pointers.ObjectManager.CurMgrOffset);
//LocalGUID = Memory.Read<UInt64>(CurrentManager + (uint) Pointers.ObjectManager.LocalGUID);
CurMgrPointer = 0x17EF770,
CurMgrOffset = 0x648,
NextObject = 0x68,
FirstObject = 0x18,
LocalGUID = 0x1D8,
}
#endregion
#region Nested type: BMAH
internal enum BMAH
{
ItemCount = 0x1757Cc8, // + CDA8
ItemStart = ItemCount + 0x08,
}
#endregion
#region Nested type: Globals
internal enum Globals
{
RedMessage = 0x16A2370,
MouseOverGUID = 0x16A3598,
LootWindow = 0x1716a24,
ChatboxIsOpen = 0x14557f0,
CursorType = 0x166878c,
IsBobbing = 0x1E0,
ArchFacing = 0x490,
ArchFacingOffset2 = 0x258,
}
#endregion
#region ActionBar enum
public enum ActionBar
{
ActionBarFirstSlot = 0x1715030,
ActionBarBonus = ActionBarFirstSlot + 0x240,
}
#endregion
#region ClickToMove enum
public enum ClickToMove
{
Offset = 0x60,
Pointer = 0x16A3148, // + 0xCD00
}
#endregion
#region AutoLoot enum
public enum AutoLoot
{
Offset = 0x60,
Pointer = 0x16A3188, // + 0xCD00
}
#endregion
#region CgUnitCGetCreatureRank enum
public enum CgUnitCGetCreatureRank
{
Offset1 = 0x16F0,
Offset2 = 0x38,
}
#endregion
#region CgUnitCGetCreatureType enum
public enum CgUnitCGetCreatureType
{
Offset1 = 0x16F0,
Offset2 = 0x30,
}
#endregion
#region CgWorldFrameGetActiveCamera enum
public enum CgWorldFrameGetActiveCamera
{
//return Memory.Read<uint>(Memory.ReadRelative<uint>((uint)Pointers.CgWorldFrameGetActiveCamera.CameraPointer)
// + (uint)Pointers.CgWorldFrameGetActiveCamera.CameraOffset);
CameraX = 0x10,
CameraY = 0x14,
CameraZ = 0x18,
CameraMatrix = 0x1C,
CameraPointer = 0x16A3A10,
CameraOffset = 0x7768,
}
#endregion
#region Nested type: AutoAttack
internal enum AutoAttack
{
//AutoAttackFlag = 0xEE8, //Old Method
//AutoAttackMask = 0xEEC, //Old Method
//Address seems to show the GUID of the Auto Attack target
AutoAttackGUID = 0x1AE0,
//Shows 0x06 when not wanding, 0x0C or 0x0E when wanding.
//Wanding = 0xEF8,
}
#endregion
#region Nested type: CastingInfo
internal enum CastingInfo
{
IsCasting = 0x1B98,
ChanneledCasting = 0x1BB8,
}
#endregion
#region Nested type: Chat
internal enum Chat : uint
{
//TODO : Go fix chat arrays and memory usage there.
//Thx for struct info Torpedoes
ChatStart = 0x16A52F0,
ChatPosition = 0x16FF84C,
OffsetToNextMsg = 0x17F0,
MsgSenderGuid = 0x00,
MsgSenderName = 0x034,
MsgFullMessage = 0x0065,
MsgOnlyMessage = 0x0C1D,
MsgChannelNum = 0x17D8,
MsgTimeStamp = 0x17E4,
}
#endregion
#region Nested type: RealId
internal enum ReadId : uint
{
DatabasePointer = 0x17010C0, // + 0xCD30
NumItems = DatabasePointer + 0x08,
ItemSize = 0x33C,
}
#endregion
#region BlueChat
internal enum Messages
{
//This is incorrect. I never use it, so haven't updated it.
//Seems to be used in updating skills?
//Same as red message?
EventMessage = 0x16A2370, // + 0xCD00
}
#endregion
//Moved to Power3
//#region Nested type: ComboPoints
// internal enum ComboPoints
// {
// ComboPoints = 0xD91411, // 5.4.8 (18414) (0x4F0 diff)
// }
//#endregion
#region Nested type: Runes
//Thx evil2
internal enum Runes
{
RuneTypes = 0x171D0d8, // + 0xCD48 //Appears to be unused.
RunesOffset = 0x171D13C, // + 0xCD48
//Offset is usually RuneTypes + 0x64
}
#endregion
#region Nested type: Container
internal enum Container
{
//Provided by Charles.
//Untested
EquippedBagGUID = 0x171D0d8, //This is not correct - It's somewhere in the area likely though.
}
#endregion
#region Nested type: KeyBinding
internal enum KeyBinding
{
NumKeyBindings = 0x17017F0,
First = 0xC8,
Next = 0xB8,
Key = 0x30,
Command = 0x58,
}
#endregion
#region Nested type: Macros
internal enum MacroManager
{
MacroCount = 0x13E8410, // + 0xCD48
MacroTable = 0x13E8420, // + 0xCD48
MacroIdOffset = 0x30,
SpecificMacroIdOffset = 0x38,
MacroNameOffset = 0x44,
}
#endregion
#region Nested type: Reaction
//Thx for struct info JuJuBoSc
internal enum Reaction
{
FactionDBCStruct = 0x14BF900, // + 0xBE18
FactionDBRows = FactionDBCStruct + 0x08,
FactionMaxIndex = FactionDBCStruct + 0x0C,
FactionMinIndex = FactionDBCStruct + 0x10,
//Naming string is at Memory.ReadUtf8(Memory.Read<uint>((uint)Pointers.Reaction.FactionDBNaming), 64);
FactionDBNaming = FactionDBCStruct + 0x18,
FactionDBData = FactionDBCStruct + 0x20,
FactionDBFirstRow = FactionDBCStruct + 0x28,
FactionDBRowSize = FactionDBCStruct + 0x54,
HostileOffset1 = 0x14,
HostileOffset2 = 0x0C,
FriendlyOffset1 = 0x10,
FriendlyOffset2 = 0x0C,
}
#endregion
/*
* //Now using the one from the descriptors offset.
#region Nested type: ShapeshiftForm
internal enum ShapeshiftForm
{
BaseAddressOffset1 = 0xE4, // 5.4.8 (18414)
BaseAddressOffset2 = 0x1E3, // 5.4.8 (18414)
}
#endregion
*/
#region Nested type: SpellCooldown
internal enum SpellCooldown : uint
{
CooldPown = 0x14DE1B0, // + 0xC8A0
}
#endregion
#region Nested type: Swimming
internal enum Swimming
{
Pointer = 0x230,
Offset = 0x58,
Mask = 0x100000,
}
#endregion
#region IsFlying enum
public enum IsFlying
{
Pointer = 0x230,
Offset = 0x58,
Mask = 0x1000000
}
#endregion
#region Nested type: UnitSpeed
internal enum UnitSpeed
{
Pointer1 = 0x230,
Pointer2 = 0xA0,
}
#endregion
#region Nested type: UnitAuras
internal enum UnitAuras : uint
{
AuraCount1 = 0x2390,
AuraCount2 = 0x1D10,
AuraTable1 = 0x1D14,
AuraTable2 = 0x1D18,
AuraSize = 0x68,
AuraSpellId = 0x50,
AuraStack = 0x59,
TimeLeft = 0x60,
OwnerGUID = 0x40,
}
#endregion
#region Nested type: UnitName
internal enum UnitName : uint
{
ObjectName1 = 0x498,
ObjectName2 = 0xD8,
PlayerNameGUIDOffset = 0x020,
PlayerNameStringOffset = 0x031,
PlayerNameCachePointer = 0x14C3FD8, // + 0xC850
UnitName1 = 0x16F0, // 0xC04,
UnitName2 = 0xA0,
}
#endregion
#region Nested type: WowObject
internal enum WowObject
{
X = 0x1548,
Y = X + 0x4,
Z = X + 0x8,
RotationOffset = X + 0x10,
GameObjectX = 0x0248,
GameObjectY = GameObjectX + 0x4,
GameObjectZ = GameObjectX + 0x8,
GameObjectRotation = GameObjectX + 0x10,
}
#endregion
#region Nested type: Zone
internal enum Zone : uint
{
ZoneText = 0x16A2F70,
ZoneID = 0x16A2FE0,
}
#endregion
#region Nested type: UiFrame
internal enum UiFrame
{
//var @base = Memory.ReadRelative<uint>((uint)Pointers.UiFrame.FrameBase);
//var currentFrame = Memory.Read<uint>(@base + (uint)Pointers.UiFrame.FirstFrame);
ScrWidth = 0x1355088,
ScrHeight = 0x135508C,
FrameBase = 0x14479d0,
CurrentFrameOffset = 0x160,
FirstFrame = 0x23E8,
NextFrame = 0x23D8,
RegionsFirst = 0x220,
RegionsNext = 0x210,
Visible = 0xC0,
Visible1 = 0x1A,
Visible2 = 1,
LabelText = 0x1A0,
Name = 0x30,
ButtonEnabledPointer = 0x1F4, //Assumed Good
ButtonEnabledMask = 0xF, //Assumed Good
ButtonChecked = 0x230, //Assumed Good
EditBoxText = 0x210, //Assumed Good
FrameBottom = 0xC4,
FrameLeft = 0xC8,
FrameTop = 0xCC,
FrameRight = 0xD0,
}
#endregion
}
}
#endif