- hooked up SW's intermission handling.

This commit is contained in:
Christoph Oelckers 2021-04-29 16:10:04 +02:00
parent aa148d602c
commit 5959543380
2 changed files with 24 additions and 30 deletions

View file

@ -142,14 +142,6 @@ void GameInterface::Render()
void GameInterface::NextLevel(MapRecord* map, int skill)
{
#if 0
// Loading is so fast on modern systems that this only serves as an irritant, not an asset.
loadscreen(map, [=](bool)
{
enterlevel(map, 0);
gameaction = ga_level;
});
#endif
enterlevel(map, 0);
}

View file

@ -88,10 +88,6 @@ CVAR(Bool, sw_bunnyrockets, false, CVAR_SERVERINFO | CVAR_CHEAT); // This is a
BEGIN_SW_NS
void Logo(const CompletionFunc& completion);
void StatScreen(int FinishAnim, CompletionFunc completion);
void pClearSpriteList(PLAYERp pp);
extern int sw_snd_scratch;
@ -546,15 +542,21 @@ void GameInterface::LevelCompleted(MapRecord *map, int skill)
StopSound();
STAT_Update(map == nullptr);
#if 0
// else if (gNet.MultiGameType != MULTI_GAME_COMMBAT)
StatScreen(FinishAnim, [=](bool)
SummaryInfo info{};
info.kills = Player->Kills;
info.maxkills = TotalKillable;
info.secrets = Player->SecretsFound;
info.maxsecrets = LevelSecrets;
info.time = PlayClock / 120;
ShowIntermission(currentLevel, map, &info, [=](bool)
{
if (map == nullptr)
{
FinishAnim = false;
PlaySong(nullptr, ThemeSongs[0], ThemeTrack[0]);
if (SW_SHAREWARE)
if (isShareware())
{
PlayOrderSound();
gameaction = ga_creditsmenu;
@ -563,7 +565,6 @@ void GameInterface::LevelCompleted(MapRecord *map, int skill)
}
else gameaction = ga_nextlevel;
});
#endif
}
//---------------------------------------------------------------------------
//
@ -591,6 +592,7 @@ void GameInterface::NewGame(MapRecord *map, int skill, bool)
ShadowWarrior::NewGame = true;
InitLevel(map);
InitRunLevel();
gameaction = ga_level;
}
//---------------------------------------------------------------------------