Skip to content

Conversation

@smix8
Copy link
Contributor

@smix8 smix8 commented Dec 12, 2024

Fixes 3D CSG not reacting to child node order changes.

While working on the 2D CSG #99911 I noticed that when I just moved csg child nodes up and down in the SceneTree order it would not update the CSG shapes.

This was because the _notifcation() code was missing the NOTIFICATION_CHILD_ORDER_CHANGED to set the dirty flags. The csg nodes only reacted to the NOTIFICATION_PARENTED and NOTIFICATION_UNPARENTED notifcations. Without a full (re)parent event it would not update. The child order is critical for the result as the CSG operations are applied in child order.

Fast forward knowing that I had copied that entire update and notification code from the 3D version here is the same fix for 3D.

Fixes 3D CSG not reacting to child node order changes.
@smix8 smix8 added this to the 4.4 milestone Dec 12, 2024
@smix8 smix8 requested a review from a team as a code owner December 12, 2024 23:37
@smix8 smix8 requested a review from fire December 12, 2024 23:40
@Repiteo Repiteo merged commit c58fbaf into godotengine:master Dec 13, 2024
20 checks passed
@Repiteo
Copy link
Contributor

Repiteo commented Dec 13, 2024

Thanks!

@smix8 smix8 deleted the csg_3d_child_notify branch December 13, 2024 22:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants