godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
91.3k stars 21.24k forks source link

Add "Follow Selection" in the 3D editor by using Center Selection twice #99499

Open Calinou opened 22 hours ago

Calinou commented 22 hours ago

When pressing the Focus Selection shortcut twice, you will begin following the current selection. This also applies to selection changes.

The effect is undone by pressing the Focus Selection shortcut another time, using the Focus Origin shortcut, or by panning/using freelook on the 3D editor camera. (Orbiting or switching between perspective and orthogonal does not undo the effect.)

Some use cases include:


Testing project: test_follow_selection.zip

Preview

Following the selection will also follow other selected nodes, so you can iterate quickly on different nodes that may be spread far away from each other:

https://github.com/user-attachments/assets/78efa041-24ae-4bb7-ad57-617dc501f486

While following the selection, you can manipulate it as usual, e.g. with Blender-style manipulation shortcuts:

https://github.com/user-attachments/assets/d91ce577-3666-480e-8b08-d515db6deee3

This also pairs well with grid snapping and Blender-style manipulation by entering units on the keyboard:

https://github.com/user-attachments/assets/0478f64d-2f59-49ce-adea-2b8aff002698

Lastly, it works with keyboard-based camera manipulation too:

https://github.com/user-attachments/assets/2bb9b05d-c7a5-4440-acf1-9d47b840c126