-
-
Notifications
You must be signed in to change notification settings - Fork 23.5k
Fix Clear Inheritance issues #111025
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 Clear Inheritance issues #111025
Conversation
bde25d0 to
319b306
Compare
319b306 to
8470819
Compare
|
Is it possible to achieve the same without saving and reloading scene? If the scene is not saved, you can "undo" the change by reloading the scene, which is useful option. You can clear scene's undo history and it will mark the scene as unsaved with no way of undo. Not sure about other problems, but it should be possible to fix them too. |
I can give it a try, but recreating the entire hierarchy, as reloading it from a file, would need lots of works. |
|
I think the problem is that For a hacky solution, calling |
In my investigation, the "Clear Inheritance" operation is not complete. It only clean Lines 2809 to 2813 in e825169
And before "Clear Inheritance", there is only one node with a reference for an "ext_resource". After "Clear Inheritance", we need create the real tree structure for the new scene. I agree the current PR is not so good. I can do more digging to find a better solution. Edit:
|
be8b9c7 to
8591ece
Compare
|
I found BTW: There is a compilation error on windows platform. Looks like ret_nodes maybe unintiliazed on some situations. I don't know how to fix it, yet. Maybe related this: #111771 |
4480a27 to
9ab4be7
Compare
9ab4be7 to
91f257d
Compare
KoBeWi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor details left, but the implementation looks ok now.
91f257d to
766b45b
Compare
|
Thanks! |
There are so many problems when invoking
Clear Inheritanceunsaved (*)mark on the title of editor.NodeDockis readonly.There latest comment gives me a clue, that we can save scene and reload scene directly, then all of these issues resolved.
Edit:
Follows KobeWi suggestion, don't save and reload scene, but update node in memory and mark unsaved.