public static bool WriteMemory(long MemoryAddress, byte[] Buffer) { uint oldProtect; Managed.VirtualProtectEx(pHandle, (IntPtr)MemoryAddress, (uint)Buffer.Length, Managed.PAGE_READWRITE, out oldProtect); IntPtr ptrBytesWritten; return(Managed.WriteProcessMemory(pHandle, MemoryAddress, Buffer, (uint)Buffer.Length, out ptrBytesWritten)); }
public static bool WriteNop(long MemoryAddress, byte[] Buffer) { IntPtr ptrBytesWritten; return(Managed.WriteProcessMemory(pHandle, MemoryAddress, Buffer, (uint)Buffer.Length, out ptrBytesWritten)); }