Path: blob/main/release-content/migration-guides/rename-clear_children.md
7222 views
------In summary, we renamed clear_* and remove_* methods to detach_*. This should clarify that these methods do not despawn the child entities or related entities.
We renamed several related methods on both EntityCommands and EntityWorldMut:
The method
EntityCommands::clear_childrenhas been renamed toEntityCommands::detach_all_children.The method
EntityWorldMut::clear_childrenhas been renamed toEntityWorldMut::detach_all_children.The method
EntityCommands::remove_childrenhas been renamed toEntityCommands::detach_children.The method
EntityWorldMut::remove_childrenhas been renamed toEntityWorldMut::detach_children.The method
EntityCommands::remove_childhas been renamed toEntityCommands::detach_child.The method
EntityWorldMut::remove_childhas been renamed toEntityWorldMut::detach_child.The method
EntityCommands::clear_relatedhas been renamed toEntityCommands::detach_all_related.The method
EntityWorldMut::clear_relatedhas been renamed toEntityWorldMut::detach_all_related.