Console works again | UI crash fixes

This commit is contained in:
2024-12-22 00:49:35 +01:00
parent 664626c838
commit f8b540f583
7 changed files with 119 additions and 9 deletions

View File

@@ -82,6 +82,14 @@ coven_init :: (window_title: string, window_width: u32, window_height: u32, full
}
coven_run :: (game_update_proc: (float), game_editor_update_proc: (float), game_update_post_physics_proc: (float)) {
if engine.current_scene == null {
last_opened_scene := get_last_opened_scene_file();
if last_opened_scene.count > 0 {
engine.current_scene = load_scene(last_opened_scene);
free(last_opened_scene);
}
}
time = xx seconds_since_init();
while !quit {