Merge pull request #87385 from Sauermann/fix-subviewport-physics-picking

Fix SubViewport physics picking
This commit is contained in:
Yuri Sizov 2024-01-25 16:27:02 +01:00
commit 91ac53ec1b
1 changed files with 8 additions and 0 deletions

View File

@ -738,6 +738,14 @@ void Viewport::_process_picking() {
while (physics_picking_events.size()) {
local_input_handled = false;
if (!handle_input_locally) {
Viewport *vp = this;
while (!Object::cast_to<Window>(vp) && vp->get_parent()) {
vp = vp->get_parent()->get_viewport();
}
vp->local_input_handled = false;
}
Ref<InputEvent> ev = physics_picking_events.front()->get();
physics_picking_events.pop_front();