From 628457b0de0762029f8ee8982c1203bcf689a2fc Mon Sep 17 00:00:00 2001 From: griffi-gh Date: Wed, 8 Feb 2023 03:09:04 +0100 Subject: [PATCH] fix --- kubi/src/world/loading.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kubi/src/world/loading.rs b/kubi/src/world/loading.rs index 2254009..307b898 100644 --- a/kubi/src/world/loading.rs +++ b/kubi/src/world/loading.rs @@ -243,6 +243,9 @@ pub fn switch_to_ingame_if_loaded( world: UniqueView, mut state: UniqueViewMut ) { + if world.chunks.is_empty() { + return + } if world.chunks.iter().all(|(_, chunk)| { chunk.desired_state.matches(chunk.current_state) }) {