-
-
Notifications
You must be signed in to change notification settings - Fork 21.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disallow selection of ownerless nodes #92188
Conversation
08d3d7c
to
609df43
Compare
I agree that having nothing shown as selected in the SceneTree is confusing, but maybe an alternative is to show some kind transient node selection that is denoted somehow (like yellow being nodes owned by another scene in the case of inherited scenes). My concern now is that you can't access and modify the ownerless nodes properties in the inspector, which might be desirable in some circumstance. |
It's possible there is use for it, but looking everything which is generally considered standard operation in Godot, I really can't think of what that might be, and as pointed out in the issue, the current behaviour directly conflicts with a otherwise perfectly viable data-driven workflow. If the goal was to provide something similar with the behaviour of instanced scenes with the editable scene flag, I think at the very least there would be a requirement to flag an ownerless node as editable too before it can be selected. |
This is consistent with 2D editor. The equivalent code is here: godot/editor/plugins/canvas_item_editor_plugin.cpp Lines 706 to 710 in 8e2141e
|
Aaah, I thought I was going crazy the other day! This happens with my spawner class, which instantiates the character scene to different positions for preview (orientation, entrance origin, destination, etc.) |
Attempts to select first node owned by the edited scene instead.
609df43
to
596026a
Compare
Thanks! |
I stumbled upon a regression that seems to have been caused by this PR, where you're no longer able to use the list of selectable (overlapping) nodes feature in the 3D editor. I put up a fix in #94387, in case anyone wants to take a look. |
I'm also noticing that the code for this list selection feature now differs between 3D and 2D, where the 3D list selection now incorporates the logic from Is that something that should be addressed? EDIT: When taking a closer look at |
Closes #92187
This changes the behaviour of node selection when selecting ownerless nodes in the 3D node editor. Now, instead of simply selecting the ownerless node, it will walk its parents and attempt to find the first node which is valid for selection.