- disabled shortcutting the intermission code if no summary screen is wanted.

This also disabled all cutscenes being attached to the completed map.
This commit is contained in:
Christoph Oelckers 2022-11-16 16:29:02 +01:00
parent 29b4418c3a
commit d0c86952ee

View file

@ -1023,11 +1023,6 @@ DIntermissionController* FLevelLocals::CreateIntermission()
void RunIntermission(level_info_t* fromMap, level_info_t* toMap, DIntermissionController* intermissionScreen, DObject* statusScreen, std::function<void(bool)> completionf) void RunIntermission(level_info_t* fromMap, level_info_t* toMap, DIntermissionController* intermissionScreen, DObject* statusScreen, std::function<void(bool)> completionf)
{ {
if (!intermissionScreen && !statusScreen)
{
completionf(false);
return;
}
cutscene.runner = CreateRunner(false); cutscene.runner = CreateRunner(false);
GC::WriteBarrier(cutscene.runner); GC::WriteBarrier(cutscene.runner);
cutscene.completion = std::move(completionf); cutscene.completion = std::move(completionf);
@ -1118,7 +1113,7 @@ void G_DoCompleted (void)
bool endgame = strncmp(nextlevel, "enDSeQ", 6) == 0; bool endgame = strncmp(nextlevel, "enDSeQ", 6) == 0;
intermissionScreen = primaryLevel->CreateIntermission(); intermissionScreen = primaryLevel->CreateIntermission();
auto nextinfo = !playinter || endgame? nullptr : FindLevelInfo(nextlevel, false); auto nextinfo = !playinter || endgame? nullptr : FindLevelInfo(nextlevel, false);
RunIntermission(playinter? primaryLevel->info : nullptr, nextinfo, intermissionScreen, statusScreen, [=](bool) RunIntermission(primaryLevel->info, nextinfo, intermissionScreen, statusScreen, [=](bool)
{ {
if (!endgame) primaryLevel->WorldDone(); if (!endgame) primaryLevel->WorldDone();
else D_StartTitle(); else D_StartTitle();
@ -1287,12 +1282,7 @@ bool FLevelLocals::DoCompleted (FString nextlevel, wbstartstruct_t &wminfo)
finishstate = mode; finishstate = mode;
if (!ShouldDoIntermission(nextcluster, thiscluster)) return ShouldDoIntermission(nextcluster, thiscluster);
{
WorldDone ();
return false;
}
return true;
} }
//========================================================================== //==========================================================================