bevy/crates/bevy_ecs/src/relationship
Alice Cecile 85eceb022d
Add insert and remove recursive methods on EntityWorldMut and EntityCommands (#17463)
# Objective

While being able to quickly add / remove components down a tree is
broadly useful (material changing!), it's particularly necessary when
combined with the newly added #13120.

## Solution

Write four methods: covering both adding and removal on both
`EntityWorldMut` and `EntityCommands`.

These methods are generic over the `RelationshipTarget`, thanks to the
freshly merged relations 🎉

## Testing

I've added a simple unit test for these methods.

---------

Co-authored-by: Zachary Harrold <zac@harrold.com.au>
2025-01-21 02:57:57 +00:00
..
mod.rs Parent -> ChildOf (#17427) 2025-01-20 22:13:29 +00:00
related_methods.rs Add insert and remove recursive methods on EntityWorldMut and EntityCommands (#17463) 2025-01-21 02:57:57 +00:00
relationship_query.rs Add an example teaching users about custom relationships (#17443) 2025-01-20 23:17:38 +00:00
relationship_source_collection.rs Support non-Vec data structures in relations (#17447) 2025-01-20 21:26:08 +00:00