diff --git a/src/visibility.rs b/src/visibility.rs index c016f46..e40b861 100644 --- a/src/visibility.rs +++ b/src/visibility.rs @@ -311,6 +311,7 @@ impl InputGrid for VisibilityGrid { fn update_viewshed( mut commands: Commands, + physics_time: Res>, mut viewers: Query<( Entity, &mut Viewshed, @@ -321,6 +322,9 @@ fn update_viewshed( sensors: Query<&Sensor>, spatial_query: SpatialQuery, ) { + if physics_time.is_paused() { + return; + } for (viewer_entity, mut viewshed, mut visible_entities, viewer_transform) in &mut viewers { viewshed.update( &mut commands,