diff options
| author | HampusM <hampus@hampusmat.com> | 2026-09-26 21:14:04 +0200 |
|---|---|---|
| committer | HampusM <hampus@hampusmat.com> | 2026-09-26 21:14:04 +0200 |
| commit | 022a9971cee14da96c6b955dd6413d060d77662b (patch) | |
| tree | 636eb6d7ffcfcd6db203f74524e086819c7995f0 | |
| parent | 68912982d8f909569e932d5373485b435c71d6b2 (diff) | |
| -rw-r--r-- | engine-ecs/src/actions.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/engine-ecs/src/actions.rs b/engine-ecs/src/actions.rs index cbf996f..69605b3 100644 --- a/engine-ecs/src/actions.rs +++ b/engine-ecs/src/actions.rs @@ -78,12 +78,18 @@ impl Actions<'_> } /// Queues up despawning a entity at the end of the current tick. + #[tracing::instrument(skip_all, fields(%entity_uid))] pub fn despawn(&mut self, entity_uid: Uid) { debug_assert!(!entity_uid.is_pair()); let Some(ent) = self.world.get_entity(entity_uid) else { - tracing::warn!("Cannot entity that doesn't exist"); + // TODO: Support for this case should probably be added + + tracing::warn!( + "Cannot queue up despawn of an entity that doesn't currently exist" + ); + return; }; |
