-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Open
Labels
C-BugAn unexpected or incorrect behaviorAn unexpected or incorrect behaviorS-Needs-TriageThis issue needs to be labelledThis issue needs to be labelled
Description
Bevy version and features
Version 0.17
What you did
Since #20204, can no longer be despawned by using the DespawnOnEnter
/DespawnOnExit
components. This is due to them being Internal
entities and thus they are not queried in the systems responsible for despawning entities.
bevy/crates/bevy_state/src/state_scoped.rs
Lines 72 to 76 in adf8211
pub fn despawn_entities_on_exit_state<S: States>( | |
mut commands: Commands, | |
mut transitions: MessageReader<StateTransitionEvent<S>>, | |
query: Query<(Entity, &DespawnOnExit<S>)>, | |
) { |
bevy/crates/bevy_state/src/state_scoped.rs
Lines 138 to 142 in adf8211
pub fn despawn_entities_on_enter_state<S: States>( | |
mut commands: Commands, | |
mut transitions: MessageReader<StateTransitionEvent<S>>, | |
query: Query<(Entity, &DespawnOnEnter<S>)>, | |
) { |
Is this intended or should observers be able to be despawned?
Metadata
Metadata
Assignees
Labels
C-BugAn unexpected or incorrect behaviorAn unexpected or incorrect behaviorS-Needs-TriageThis issue needs to be labelledThis issue needs to be labelled