-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Open
Labels
A-ScenesSerialized ECS data stored on the diskSerialized ECS data stored on the diskC-BugAn unexpected or incorrect behaviorAn unexpected or incorrect behaviorS-Needs-DesignThis issue requires design work to think about how it would best be accomplishedThis issue requires design work to think about how it would best be accomplished
Description
Bevy version
0.16.0
What you did
Spawned a scene with a hierarchy where children are defined before parents, and all have a Transform
component.
What went wrong
This results in a false-positive warning like:
warning[B0004]: The `0vX` entity with the GlobalTransform component has a parent without GlobalTransform.
This happens because the check is implemented in this hook, which runs on insertion.
I think we should turn this check into a disableable system that iterates over entities with Added<C>
.
Temporary workaround
Users can create a separate component that, on insertion, adds ChildOf
using commands. This causes the check to be delayed until after all entities are spawned.
Additional information
This also happens with bevy_replicon
during replication when a child is processed before its parent.
mirsella, vk098123 and kristoff3r
Metadata
Metadata
Assignees
Labels
A-ScenesSerialized ECS data stored on the diskSerialized ECS data stored on the diskC-BugAn unexpected or incorrect behaviorAn unexpected or incorrect behaviorS-Needs-DesignThis issue requires design work to think about how it would best be accomplishedThis issue requires design work to think about how it would best be accomplished