mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-18 15:32:33 +00:00
Add "tutorialmode" var to help the game know when we're in a tutorial or not, add placeholder for tutorial HUD to test it works
This commit is contained in:
parent
bcc9e58d0e
commit
aba9bd13bb
6 changed files with 20 additions and 0 deletions
|
@ -714,6 +714,9 @@ void D_StartTitle(void)
|
||||||
// reset modeattacking
|
// reset modeattacking
|
||||||
modeattacking = ATTACKING_NONE;
|
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
|
// empty maptol so mario/etc sounds don't play in sound test when they shouldn't
|
||||||
maptol = 0;
|
maptol = 0;
|
||||||
|
|
||||||
|
|
|
@ -1815,6 +1815,8 @@ static void Command_Map_f(void)
|
||||||
else
|
else
|
||||||
fromlevelselect = ((netgame || multiplayer) && ((gametype == newgametype) && (newgametype == GT_COOP)));
|
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);
|
D_MapChange(newmapnum, newgametype, false, newresetplayers, 0, false, fromlevelselect);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -133,6 +133,7 @@ extern boolean hidetitlepics;
|
||||||
extern INT16 bootmap; //bootmap for loading a map on startup
|
extern INT16 bootmap; //bootmap for loading a map on startup
|
||||||
|
|
||||||
extern INT16 tutorialmap; // map to load for tutorial
|
extern INT16 tutorialmap; // map to load for tutorial
|
||||||
|
extern boolean tutorialmode; // are we in a tutorial right now?
|
||||||
|
|
||||||
extern boolean looptitle;
|
extern boolean looptitle;
|
||||||
|
|
||||||
|
|
|
@ -128,6 +128,7 @@ boolean hidetitlepics = false;
|
||||||
INT16 bootmap; //bootmap for loading a map on startup
|
INT16 bootmap; //bootmap for loading a map on startup
|
||||||
|
|
||||||
INT16 tutorialmap = 0; // map to load for tutorial
|
INT16 tutorialmap = 0; // map to load for tutorial
|
||||||
|
boolean tutorialmode = false; // are we in a tutorial right now?
|
||||||
|
|
||||||
boolean looptitle = false;
|
boolean looptitle = false;
|
||||||
|
|
||||||
|
|
|
@ -6139,6 +6139,8 @@ static void M_StartTutorial(INT32 choice)
|
||||||
if (!tutorialmap)
|
if (!tutorialmap)
|
||||||
return; // no map to go to, don't bother
|
return; // no map to go to, don't bother
|
||||||
|
|
||||||
|
tutorialmode = true; // turn on tutorial mode
|
||||||
|
|
||||||
emeralds = 0;
|
emeralds = 0;
|
||||||
M_ClearMenus(true);
|
M_ClearMenus(true);
|
||||||
gamecomplete = false;
|
gamecomplete = false;
|
||||||
|
|
|
@ -2465,6 +2465,13 @@ static void ST_overlayDrawer(void)
|
||||||
ST_drawDebugInfo();
|
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)
|
void ST_Drawer(void)
|
||||||
{
|
{
|
||||||
#ifdef SEENAMES
|
#ifdef SEENAMES
|
||||||
|
@ -2538,4 +2545,8 @@ void ST_Drawer(void)
|
||||||
ST_overlayDrawer();
|
ST_overlayDrawer();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Draw tutorial text over everything else
|
||||||
|
if (tutorialmode)
|
||||||
|
ST_drawTutorial();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue