mousing out of window, kill input

Subscribe to mousing out of window, kill input 3 posts, 2 voices

 
 
bkk204 2 posts

when you mouse out of the client window, any keyboard input is still retained, IE, rotate with the left arrow, and lose focus of the 3d client frame, then release the arrow key- notice you keep spinning.

Try checking in update-
if(Input.mousePosition.x > width && Input.mousePosition.x < 0 &&Input.mousePosition.y > height && Input.mousePosition.y < 0){
Input.ResetInputAxes();
}
If you guys are using the engine I think you are ;)

 
 
Infirmo Administrator 56 posts

Good bug. Not sure if your suggestion will work for us, but we’ll get it fixed.

Thanks!

 
 
bkk204 2 posts

It seemed like you guys were on a source license variant of the unity engine, hence the code suggestion.