-
-
Notifications
You must be signed in to change notification settings - Fork 97
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
Add an option to reset the transform of the root node when saving a branch as an instanced scene #3962
Comments
I'm struggling to find a reason on why this shouldn't be the case by default. The current way leads to the |
I think having this "reset transform" behavior as the default is a good idea, but I don't know if some people will want the old behavior back. |
I believe the current behaviour only makes sense if the parent Node isn't Node2D, since it would not be able to inherit the position from anything. |
I tried to implement this (without knowing about the proposal). During the process the following questions were brought up:
Given that this proposal is here since more then a year and no usecase against it was brought up, I think that we can answer the first point with no. However I would like to address the question about other transformations. Taking the idea of checkboxes from this proposal I could imagine having three checkboxes with only the translation checked by default. This would give users controll over the behaviour. However I don't know where I would place such checkboxes and maybe the additional checkboxes would be distracting and confusing for most users. In that case I think it would be reasonable to just reset position right now. |
I personally believe having a checkbox in the editor settings to use the old way would be a good idea just for the freedom of having the option, but using this proposed solution by default sounds like the a good way to go. As for things like rotation and scale, I think if someone has scaled and rotated something, that should be applied to the saved scene from the branch. Something like rotation and scale seems very deliberate and intentional, whereas I know a lot of people will position something in the level just to test that it works before saving off as a separate scene. |
I could imagine that scale and rotation would be interesting for saving decoration objects that might have been placed to fit with the rest of a level. But going ahead with translation should be fine. If issues are raised about other transforms, adding them later should be no problem |
+1 on this issue. I think this is intuitive, and...it's also the way Unity does it, for precedence. Something related that perhaps we can piggyback on this same issue is 20231201073134.mp4 |
Also taking care of that issue here, because I felt the same way |
Did this go anywhere? |
godotengine/godot#80561 implements this, but it's not been merged yet. It also happens always rather than being an option. |
Would love to see this get added! |
You can see the related PR was merged and this is closed? |
Describe the project you are working on
unrelated
Describe the problem or limitation you are having in your project
When saving a branch as a scene, the transform of the root node in the new scene is the transform the node had originally:
drag_and_drop_2-2022-02-12_20.02.58.mp4
However, when saving a branch as a scene the idea is in my experience almost always to "promote" a subtree and make it a component on its own, which has no reason not to be centered in its own scene.
What I have to do in the current state of things to achieve this is:
Describe the feature / enhancement and how it helps to overcome the problem or limitation
Therefore imo it makes sense to add a checkbox somewhere in the "save branch as scene" dialog, titled "reset root transform" and checked by default that if checked does the following:
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
see above.
If this enhancement will not be used often, can it be worked around with a few lines of script?
I am not sure wether this feature is used often at all. I do use it often. It can't be a script.
Is there a reason why this should be core and not an add-on in the asset library?
I don't know if it can.
The text was updated successfully, but these errors were encountered: