diff --git a/src/d_main.c b/src/d_main.c index 95af1f754..c6dd9dc46 100644 --- a/src/d_main.c +++ b/src/d_main.c @@ -714,6 +714,9 @@ void D_StartTitle(void) // reset modeattacking modeattacking = ATTACKING_NONE; + // The title screen is obviously not a tutorial! (Unless I'm mistaken) + tutorialmode = false; + // empty maptol so mario/etc sounds don't play in sound test when they shouldn't maptol = 0; diff --git a/src/d_netcmd.c b/src/d_netcmd.c index f9f960a70..e96d98f11 100644 --- a/src/d_netcmd.c +++ b/src/d_netcmd.c @@ -1815,6 +1815,8 @@ static void Command_Map_f(void) else fromlevelselect = ((netgame || multiplayer) && ((gametype == newgametype) && (newgametype == GT_COOP))); + tutorialmode = false; // warping takes us out of tutorial mode + D_MapChange(newmapnum, newgametype, false, newresetplayers, 0, false, fromlevelselect); } diff --git a/src/doomstat.h b/src/doomstat.h index 1f78710e2..9a3bff7c0 100644 --- a/src/doomstat.h +++ b/src/doomstat.h @@ -133,6 +133,7 @@ extern boolean hidetitlepics; extern INT16 bootmap; //bootmap for loading a map on startup extern INT16 tutorialmap; // map to load for tutorial +extern boolean tutorialmode; // are we in a tutorial right now? extern boolean looptitle; diff --git a/src/g_game.c b/src/g_game.c index 4b2877f95..38289bcb2 100644 --- a/src/g_game.c +++ b/src/g_game.c @@ -128,6 +128,7 @@ boolean hidetitlepics = false; INT16 bootmap; //bootmap for loading a map on startup INT16 tutorialmap = 0; // map to load for tutorial +boolean tutorialmode = false; // are we in a tutorial right now? boolean looptitle = false; diff --git a/src/m_menu.c b/src/m_menu.c index 103e629de..41fb1319d 100644 --- a/src/m_menu.c +++ b/src/m_menu.c @@ -6139,6 +6139,8 @@ static void M_StartTutorial(INT32 choice) if (!tutorialmap) return; // no map to go to, don't bother + tutorialmode = true; // turn on tutorial mode + emeralds = 0; M_ClearMenus(true); gamecomplete = false; diff --git a/src/st_stuff.c b/src/st_stuff.c index fa13e008a..246bae8bc 100644 --- a/src/st_stuff.c +++ b/src/st_stuff.c @@ -2465,6 +2465,13 @@ static void ST_overlayDrawer(void) ST_drawDebugInfo(); } +static void ST_drawTutorial(void) +{ + // Nothing, ...yet + // Except this for now, just to check it works + V_DrawCenteredString(BASEVIDWIDTH/2, BASEVIDHEIGHT/2, 0, "Tutorial placeholder"); +} + void ST_Drawer(void) { #ifdef SEENAMES @@ -2538,4 +2545,8 @@ void ST_Drawer(void) ST_overlayDrawer(); } } + + // Draw tutorial text over everything else + if (tutorialmode) + ST_drawTutorial(); }