Deprecate SpatialBundle#15830
Conversation
Can you check the issues for these? I think the former is not yet reported. |
There was a problem hiding this comment.
Shouldn't Visibility::default() be added on these removals too?
There was a problem hiding this comment.
The bounding example actually doesn't use visibility at all (nor GlobalTransform), I created this example but I'm not sure why I used SpatialBundle instead of just Transform.
| .insert(FogVolume { | ||
| commands.spawn(( | ||
| Transform::from_xyz(0.0, 0.5, 0.0), | ||
| FogVolume { |
There was a problem hiding this comment.
This should also have Visibility::Visible right? I assume FogVolume would be requiring Visibility::default() if not. It might not matter though...
There was a problem hiding this comment.
Same as above, in this case FogVolume requires Visibility which means it defaults to Inherited, and functions as visible.
There was a problem hiding this comment.
Thanks for addressing my comments!
tom-frantz
left a comment
There was a problem hiding this comment.
Looks good to me! @mnmaita 's comments look like they were all covered, and the other examples had the necessary required components. I didn't see any other uses of SpatialBundle throughout the code base either, so I'm happy to approve given alice-i-cecile 's comments are covered too!
Objective
SpatialBundleis yet to be deprecatedSolution
SpatialBundleTransformandVisibilityinstead in examples using itspawnorinsertinserting a defaultTransformorVisibilitywith component already requiring either, remove those components from the tupleTesting
Yes, I ran the examples I changed and tests
The
gamepad_viewerand andcustom_shader_instancingexamples don't work as intended due to entirely unrelated code, didn't check main.Run examples, or just check that all spawned values are identical
Linux, wayland trough x11 (cause that's the default feature)
Migration Guide
SpatialBundleis now deprecated, insertTransformandVisibilityinstead which will automatically insert all other components that were in the bundle. If you do not specify these values and any other components in yourspawn/insertcall already requires either of these components you can leave that one out.before:
after: