Convert System.IntPtr To System.Runtime.InteropServices.HandleRef
Working on an external ESP hack for BO2 in C#
But ehh I'm getting this error message:
Code:
Argument 1: cannot convert from 'System.IntPtr' to 'System.Runtime.InteropServices.HandleRef'
This is ma code:
Code:
GetWindowRect(handle, out rect);
("handle" is the red marked wrong code)
This is ma DLLImport:
Code:
[DllImport("user32.dll")]
[return: MarshalAs(UnmanagedType.Bool)]
static extern bool GetWindowRect(HandleRef hWnd, out RECT lpRect);
I ned halp ples I beg u