From c061044d7875f1c7a717fddbf03cab5a822e7d35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pedro=20J=2E=20Est=C3=A9banez?= Date: Mon, 10 Jul 2017 17:37:28 +0200 Subject: [PATCH] Fix picking list flood while mouse capture enabled Fixes #9575. --- scene/main/viewport.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scene/main/viewport.cpp b/scene/main/viewport.cpp index 3a9968d126a..4fb4e02148c 100644 --- a/scene/main/viewport.cpp +++ b/scene/main/viewport.cpp @@ -2352,7 +2352,7 @@ void Viewport::unhandled_input(const Ref &p_event) { if (physics_object_picking && !get_tree()->input_handled) { - if (p_event->cast_to() || p_event->cast_to() || p_event->cast_to() || p_event->cast_to()) { + if (Input::get_singleton()->get_mouse_mode() != Input::MOUSE_MODE_CAPTURED && (p_event->cast_to() || p_event->cast_to() || p_event->cast_to() || p_event->cast_to())) { physics_picking_events.push_back(p_event); } }