From 0c33b4ab1b5f3811e6fbedb4c604e0c9b989ffcc Mon Sep 17 00:00:00 2001 From: Nitwel Date: Tue, 21 Nov 2023 11:51:33 +0100 Subject: [PATCH] fix app crashing on no walls --- content/ui/menu/room/room_menu.gd | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/content/ui/menu/room/room_menu.gd b/content/ui/menu/room/room_menu.gd index 0af5ed3..144b8f2 100644 --- a/content/ui/menu/room/room_menu.gd +++ b/content/ui/menu/room/room_menu.gd @@ -32,6 +32,10 @@ func _ready(): wall_corners.visible = false wall_edges.visible = false wall_mesh.mesh = generate_mesh() + + if wall_mesh.mesh == null: + return + var collisions = generate_collision(wall_mesh.mesh) for old_coll in wall_collisions.get_children():