ReadByte() публичный Метод

public ReadByte ( bool AddToImageAddress, int pOffset ) : byte
AddToImageAddress bool
pOffset int
Результат byte
Пример #1
0
        public void Update(Process proc, int ClientBase, int ClientSize, int EngineBase, int EngineSize)
        {
            ProcessMemory Mem = new ProcessMemory(proc.Id);

            Mem.StartProcess();

            SigScan ClientScan = new SigScan(proc, new IntPtr(ClientBase), ClientSize);
            SigScan EngineScan = new SigScan(proc, new IntPtr(EngineBase), EngineSize);

            IntPtr ptr = ClientScan.FindPattern(new byte[] { 0x05, 0x00, 0x00, 0x00, 0x00, 0xC1, 0xE9, 0x00, 0x39, 0x48, 0x04 }, "x????xx?xxx", 0);
            int    p1  = Mem.ReadInt((int)ptr + 1);
            byte   p2  = Mem.ReadByte((int)ptr + 7);

            m_dwEntityList = (p1 + p2) - ClientBase;

            ptr             = ClientScan.FindPattern(new byte[] { 0x8D, 0x34, 0x85, 0x00, 0x00, 0x00, 0x00, 0x89, 0x15, 0x00, 0x00, 0x00, 0x00, 0x8B, 0x41, 0x08, 0x8B, 0x48, 0x00 }, "xxx????xx????xxxxx?", 0);
            p1              = Mem.ReadInt((int)ptr + 3);
            p2              = Mem.ReadByte((int)ptr + 18);
            m_dwLocalPlayer = (p1 + p2) - ClientBase;

            ptr            = ClientScan.FindPattern(new byte[] { 0xF3, 0x0F, 0x6F, 0x05, 0x00, 0x00, 0x00, 0x00, 0x8D, 0x85 }, "xxxx????xx", 0);
            p1             = Mem.ReadInt((int)ptr + 4) + 0xB0;
            m_dwViewMatrix = p1 - ClientBase;

            ptr            = ClientScan.FindPattern(new byte[] { 0xA1, 0x00, 0x00, 0x00, 0x00, 0xA8, 0x01, 0x75, 0x00, 0x0F, 0x57, 0xC0, 0xC7, 0x05 }, "x????xxx?xxxxx", 0);
            m_dwGlowObject = Mem.ReadInt((int)ptr + 0x58) - ClientBase;

            ptr           = ClientScan.FindPattern(new byte[] { 0x89, 0x15, 0x00, 0x00, 0x00, 0x00, 0x8B, 0x15, 0x00, 0x00, 0x00, 0x00, 0xF6, 0xC2, 0x03, 0x74, 0x03, 0x83, 0xCE, 0x08, 0xA8, 0x08, 0xBF }, "xx????xx????xxxxxxxxxxx", 0);
            m_dwForceJump = Mem.ReadInt((int)ptr + 2) - ClientBase;

            ptr             = ClientScan.FindPattern(new byte[] { 0x89, 0x15, 0x00, 0x00, 0x00, 0x00, 0x8B, 0x15, 0x00, 0x00, 0x00, 0x00, 0xF6, 0xC2, 0x03, 0x74, 0x03, 0x83, 0xCE, 0x04, 0xA8, 0x04, 0xBF }, "xx????xx????xxxxxxxxxxx", 0);
            m_dwForceAttack = Mem.ReadInt((int)ptr + 2) - ClientBase;

            ptr             = ClientScan.FindPattern(new byte[] { 0xF3, 0x0F, 0x10, 0x05, 0x00, 0x00, 0x00, 0x00, 0xEB, 0x0F, 0x8B, 0x01, 0x8B, 0x40, 0x30, 0xFF, 0xD0, 0xD9, 0x5D, 0x0C, 0xF3, 0x0F, 0x10, 0x45, 0x0C, 0xF3, 0x0F, 0x11 }, "xxxx????xxxxxxxxxxxxxxxxxxxx", 0);
            m_dwSensitivity = Mem.ReadInt((int)ptr + 4) - ClientBase;
            m_dwMouseEnable = m_dwSensitivity + 0x5C;

            ptr            = ClientScan.FindPattern(new byte[] { 0x56, 0x57, 0x8B, 0xF9, 0xC7, 0x87, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8B, 0x0D, 0x00, 0x00, 0x00, 0x00, 0x81, 0xF9, 0x00, 0x00, 0x00, 0x00, 0x75, 0x07, 0xA1, 0x00, 0x00, 0x00, 0x00, 0xEB, 0x07 }, "xxxxxx????????xx????xx????xxx????xx", 0);
            m_iCrossHairID = Mem.ReadInt((int)ptr + 6);

            ptr             = EngineScan.FindPattern(new byte[] { 0xF3, 0x0F, 0x5C, 0xC1, 0xF3, 0x0F, 0x10, 0x15, 0x00, 0x00, 0x00, 0x00, 0x0F, 0x2F, 0xD0, 0x76, 0x04, 0xF3, 0x0F, 0x58, 0xC1, 0xA1, 0x00, 0x00, 0x00, 0x00, 0xF3, 0x0F, 0x11, 0x80, 0x00, 0x00, 0x00, 0x00, 0xD9, 0x46, 0x04 }, "xxxxxxxx????xxxxxxxxxx????xxxx????xxx", 0);
            m_dwClientState = Mem.ReadInt((int)ptr + 22) - EngineBase;
            m_dwViewAngles  = Mem.ReadInt((int)ptr + 30);

            ptr           = ClientScan.FindPattern(new byte[] { 0xA1, 0x00, 0x00, 0x00, 0x00, 0x8B, 0x0C, 0xB0, 0x8B, 0x01, 0xFF, 0x50, 0x00, 0x46, 0x3B, 0x35, 0x00, 0x00, 0x00, 0x00, 0x7C, 0xEA, 0x8B, 0x0D, 0x00, 0x00, 0x00, 0x00 }, "x????xxxxxxx?xxx????xxxx????", 0);
            m_dwRadarBase = Mem.ReadInt((int)ptr + 1) - ClientBase;

            ptr          = ClientScan.FindPattern(new byte[] { 0xF3, 0x0F, 0x10, 0x96, 0x00, 0x00, 0x00, 0x00, 0x0F, 0x57, 0xDB, 0x0F, 0x2F, 0xD3, 0x0F, 0x86, 0x00, 0x00, 0x00, 0x00 }, "xxxx????xxxxxxxx????", 0);
            m_iGlowIndex = Mem.ReadInt((int)ptr + 4) + 0x18;
        }
Пример #2
0
        public static int PlayerCount()
        {
            int ret = Game.ReadByte(new IntPtr(
                                        Game.ReadInt32(new IntPtr(
                                                           Game.ReadInt32(new IntPtr(
                                                                              0x140473760
                                                                              )) + 0x20
                                                           )) + 0xB4
                                        ));

            if (ret > 4)
            {
                ret = 0;
            }
            if (ret < 0)
            {
                ret = 0;
            }

            return(ret);
        }
Пример #3
0
 public static bool ReadBinary(this ProcessMemory pm, int index, IntPtr pOffset, params long[] offsets) => (pm.ReadByte(pm.Traverse(pOffset, offsets)) & (1 << index)) != 0;
Пример #4
0
 public static bool InSwap() =>
 Game.ReadByte(new IntPtr(0x140598BB8)) == 5;