Advertisement

SharpDX DirectInput Mouse Position no events

Started by November 21, 2021 11:55 PM
0 comments, last by bogdan7 3 years ago

I tried:

RenderInitialize(){
	DirectInput InputManager = new DirectInput();
}
RenderLoop(){
	Mouse mouse = new Mouse(InputManager);
	MouseState mouseState = new MouseState
	mouse.Acquire();
	mouse.getCurrentState(ref mouseState);
	Console.WriteLine("X: " + mouseState.X + " Y: " + mouseState.Y);
}

It prints (0, 0) always no matter where I place the mouse.

This topic is closed to new replies.

Advertisement