diff options
| author | Pedro J. Estébanez | 2017-07-10 17:37:28 +0200 |
|---|---|---|
| committer | Pedro J. Estébanez | 2017-07-10 17:48:57 +0200 |
| commit | c061044d7875f1c7a717fddbf03cab5a822e7d35 (patch) | |
| tree | c7ae81d1ccb698c7d3a519eddb278dd7d26d47a1 /scene/main/viewport.cpp | |
| parent | 444354b51f8f9a3be9805d137f890302c02de0db (diff) | |
| download | godot-c061044d7875f1c7a717fddbf03cab5a822e7d35.tar.gz godot-c061044d7875f1c7a717fddbf03cab5a822e7d35.tar.zst godot-c061044d7875f1c7a717fddbf03cab5a822e7d35.zip | |
Fix picking list flood while mouse capture enabled
Fixes #9575.
Diffstat (limited to '')
| -rw-r--r-- | scene/main/viewport.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/main/viewport.cpp b/scene/main/viewport.cpp index 3a9968d12..4fb4e0214 100644 --- a/scene/main/viewport.cpp +++ b/scene/main/viewport.cpp @@ -2352,7 +2352,7 @@ void Viewport::unhandled_input(const Ref<InputEvent> &p_event) { if (physics_object_picking && !get_tree()->input_handled) { - if (p_event->cast_to<InputEventMouseButton>() || p_event->cast_to<InputEventMouseMotion>() || p_event->cast_to<InputEventScreenDrag>() || p_event->cast_to<InputEventScreenTouch>()) { + if (Input::get_singleton()->get_mouse_mode() != Input::MOUSE_MODE_CAPTURED && (p_event->cast_to<InputEventMouseButton>() || p_event->cast_to<InputEventMouseMotion>() || p_event->cast_to<InputEventScreenDrag>() || p_event->cast_to<InputEventScreenTouch>())) { physics_picking_events.push_back(p_event); } } |
