From f5722b7569f2b6e1547b30751860875df1298f5c Mon Sep 17 00:00:00 2001 From: toaster Date: Mon, 18 Dec 2023 01:10:37 +0000 Subject: [PATCH] Intro adjustments - Force to play when selecting "START GAME" from the Goner Setup - Make far shorter on the First Boot, obscuring the extended Kart Krew vroom, to prevent it playing identically twice - Prevent skipping the intro at all if Ring Cup hasn't been unlocked - Both for the shortened initial startup and the START GAME first encounter - It already clears dirmenu if relevant, don't do that twice --- src/d_netcmd.c | 3 --- src/f_finale.c | 14 ++++++++++++-- src/menus/main-goner.cpp | 2 ++ 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/src/d_netcmd.c b/src/d_netcmd.c index 386182a4a..b6825d3e3 100644 --- a/src/d_netcmd.c +++ b/src/d_netcmd.c @@ -4795,9 +4795,6 @@ static void Command_Playintro_f(void) if (netgame) return; - if (dirmenu) - closefilemenu(true); - F_StartIntro(); } diff --git a/src/f_finale.c b/src/f_finale.c index 66eea452d..f1aa884f2 100644 --- a/src/f_finale.c +++ b/src/f_finale.c @@ -303,6 +303,8 @@ static tic_t introscenetime[NUMINTROSCENES] = // custom intros void F_StartCustomCutscene(INT32 cutscenenum, boolean precutscene, boolean resetplayer); +static boolean skippableallowed = true; + void F_StartIntro(void) { if (gamestate) @@ -315,6 +317,11 @@ void F_StartIntro(void) D_ClearState(); } + skippableallowed = ( + gamestartchallenge >= MAXUNLOCKABLES + || (gamedata && gamedata->unlocked[gamestartchallenge]) + ); + M_ClearMenus(false); D_SetDeferredStartTitle(false); @@ -459,7 +466,7 @@ void F_IntroTicker(void) timetonext--; - if (D_IsDeferredStartTitle()) + if (skippableallowed && D_IsDeferredStartTitle()) { D_StartTitle(); return; @@ -468,7 +475,10 @@ void F_IntroTicker(void) if (timetonext <= 0) { intro_scenenum++; - if (intro_scenenum == NUMINTROSCENES) + if (intro_scenenum == (M_GameTrulyStarted() + ? NUMINTROSCENES + : INTROSCENE_KREW) + ) { D_StartTitle(); // Custom built fade to skip the to-black diff --git a/src/menus/main-goner.cpp b/src/menus/main-goner.cpp index 7040cd9cb..b3f5adeb8 100644 --- a/src/menus/main-goner.cpp +++ b/src/menus/main-goner.cpp @@ -5,6 +5,7 @@ #include "../m_cond.h" #include "../r_skins.h" #include "../s_sound.h" +#include "../f_finale.h" #include "../music.h" #include "../p_local.h" // P_AutoPause #include "../st_stuff.h" // faceprefix @@ -1178,6 +1179,7 @@ static void M_GonerConclude(INT32 choice) gamedata->gonerlevel = GDGONER_DONE; + F_StartIntro(); M_ClearMenus(true); M_GonerResetText(); }