-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
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
Fix duplicating multiple nodes at different depths in SceneTreeDock
#86211
Conversation
This changes how nodes on the same level are duplicated: godot.windows.editor.dev.x86_64_dmAeG1gXuZ.mp4vs old godot_Hsbxsczcj5.mp4I don't think that's expected behavior. Especially the order is garbled (reminiscent of this old issue #38162, which the code you removed fixed) |
Question: You duplicate (both nodes, same level):
Is the desired result:
or:
|
I'd say the latter. In case of
Expected result is
In your example, the latter result is consistent with the above. |
Understood, but I need to ask another question about desired behaviour:
You select |
Currently you'd end up with
I think you should keep the current behavior for nodes on the same level and only fix duplication with different parents. |
Understood. Thank you for explaining. |
7809622
to
ed64879
Compare
Amended PR and pushed. Like you asked, it sticks with current behavior for nodes on the same level, but still handles having nodes with different parents. |
SceneTreeDock
SceneTreeDock
Thanks! |
Cherry-picked for 4.2.2. |
Fixes #84333.
Duplicating multiple nodes at different depths seemed to put all the new nodes on the same level, which was counterintuitive. Also, undoing this operation was bugged.
I've fixed it so that each duplicated node appears next to the node it was duplicated from at whatever depth it was at. This also fixed the Undo functionality.