From 2ea41a63d9f6f3ebd095ac38610f53ac01f1191e Mon Sep 17 00:00:00 2001 From: "BADIM-PC\\Vadim" Date: Thu, 28 Sep 2017 17:20:27 +0300 Subject: [PATCH] bug in SURF #304 --- src/console.c | 2 +- src/studio.c | 6 ++++++ src/studio.h | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/console.c b/src/console.c index b761316..967a980 100644 --- a/src/console.c +++ b/src/console.c @@ -847,7 +847,7 @@ static void onConsoleInstallDemosCommand(Console* console, const char* param) static void onConsoleSurfCommand(Console* console, const char* param) { - setStudioMode(TIC_SURF_MODE); + gotoSurf(); commandDone(console); } diff --git a/src/studio.c b/src/studio.c index 4ae57f3..a4e0085 100644 --- a/src/studio.c +++ b/src/studio.c @@ -719,6 +719,12 @@ static void initSurfMode() initSurf(&studio.surf, studio.tic, &studio.console); } +void gotoSurf() +{ + initSurfMode(); + setStudioMode(TIC_SURF_MODE); +} + static void initMenuMode() { initMenu(&studio.menu, studio.tic, studio.fs); diff --git a/src/studio.h b/src/studio.h index 536725b..7c2691d 100644 --- a/src/studio.h +++ b/src/studio.h @@ -197,4 +197,5 @@ bool studioCartChanged(); void playSystemSfx(s32 id); void runGameFromSurf(); +void gotoSurf(); void exitFromGameMenu(); \ No newline at end of file