/// <summary> /// Get the Position of the GameView. (Use this informations if you have some troubles with windowed Applications) /// </summary> /// <returns></returns> public static Vector2 GetGameViewPosition() { Win32HelperClass.Point position = new Win32HelperClass.Point(); pointerToGameWindow = Win32HelperClass.GetForegroundWindow(); Win32HelperClass.ClientToScreen(pointerToGameWindow, ref position); return(new Vector2(position.x, position.y)); }
/// <summary> /// Get the Position of the GameView. (Use this informations if you have some troubles with windowed Applications) /// </summary> /// <returns></returns> public static Vector2 GetGameViewPosition() { Win32HelperClass.Point position = new Win32HelperClass.Point(); pointerToGameWindow = Win32HelperClass.GetForegroundWindow(); Win32HelperClass.ClientToScreen(pointerToGameWindow, ref position); return new Vector2(position.x, position.y); }