mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-29 23:33:00 +00:00
- SCreenjob fixes
Still doesn’r show anything but we got it all set up now.
This commit is contained in:
parent
54329bd87b
commit
336c45aaa4
6 changed files with 26 additions and 13 deletions
|
@ -312,16 +312,14 @@ bool StartCutscene(CutsceneDef& cs, int flags, const CompletionFunc& completion_
|
|||
cs.Create(runner);
|
||||
if (!ScreenJobValidate())
|
||||
{
|
||||
runner->Destroy();
|
||||
runner = nullptr;
|
||||
DeleteScreenJob();
|
||||
return false;
|
||||
}
|
||||
if (sysCallbacks.StartCutscene) sysCallbacks.StartCutscene(flags & SJ_BLOCKUI);
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
if (runner) runner->Destroy();
|
||||
runner = nullptr;
|
||||
DeleteScreenJob();
|
||||
throw;
|
||||
}
|
||||
return true;
|
||||
|
|
|
@ -3385,6 +3385,7 @@ static int D_DoomMain_Internal (void)
|
|||
|
||||
R_ParseTrnslate();
|
||||
PClassActor::StaticInit ();
|
||||
Job_Init();
|
||||
|
||||
// [GRB] Initialize player class list
|
||||
SetupPlayerClasses ();
|
||||
|
|
|
@ -1190,6 +1190,7 @@ void G_Ticker ()
|
|||
break;
|
||||
case ga_intermission:
|
||||
gamestate = GS_CUTSCENE;
|
||||
gameaction = ga_nothing;
|
||||
break;
|
||||
|
||||
|
||||
|
|
|
@ -956,8 +956,7 @@ void RunIntermission(DIntermissionController* intermissionScreen, DObject* statu
|
|||
|
||||
if (!ScreenJobValidate())
|
||||
{
|
||||
runner->Destroy();
|
||||
runner = nullptr;
|
||||
DeleteScreenJob();
|
||||
if (completion) completion(false);
|
||||
completion = nullptr;
|
||||
return;
|
||||
|
@ -1010,7 +1009,11 @@ void G_DoCompleted (void)
|
|||
}
|
||||
bool endgame = intermissionScreen && intermissionScreen->mEndGame;
|
||||
intermissionScreen = primaryLevel->CreateIntermission();
|
||||
RunIntermission(intermissionScreen, statusScreen, [=](bool) { if (!endgame) primaryLevel->WorldDone(); });
|
||||
RunIntermission(intermissionScreen, statusScreen, [=](bool)
|
||||
{
|
||||
if (!endgame) primaryLevel->WorldDone();
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
|
|
|
@ -19,7 +19,11 @@ class IntermissionScreenJob : ScreenJob
|
|||
{
|
||||
IntermissionController controller;
|
||||
|
||||
void Init(IntermissionController ctrl) { controller = ctrl; }
|
||||
ScreenJob Init(IntermissionController ctrl)
|
||||
{
|
||||
controller = ctrl;
|
||||
return self;
|
||||
}
|
||||
|
||||
override bool OnEvent(InputEvent evt) { return controller.Responder(evt); }
|
||||
override void OnTick() { if (!controller.Ticker()) jobstate = finished; }
|
||||
|
@ -37,9 +41,10 @@ class StatusScreenJob : SkippableScreenJob
|
|||
{
|
||||
StatusScreen controller;
|
||||
|
||||
void Init(StatusScreen scr)
|
||||
ScreenJob Init(StatusScreen scr)
|
||||
{
|
||||
controller = scr;
|
||||
return self;
|
||||
}
|
||||
|
||||
override void OnTick() { controller.Ticker(); if (controller.CurState == StatusScreen.LeavingIntermission) jobstate = finished; }
|
||||
|
@ -54,7 +59,7 @@ class StatusScreenJob : SkippableScreenJob
|
|||
}
|
||||
|
||||
|
||||
class DoomCutscenes
|
||||
class DoomCutscenes ui
|
||||
{
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// Note that the status screen needs to run in 'play' scope!
|
||||
|
||||
class InterBackground native play version("2.5")
|
||||
class InterBackground native ui version("2.5")
|
||||
{
|
||||
native static InterBackground Create(wbstartstruct wbst);
|
||||
native virtual bool LoadBackground(bool isenterpic);
|
||||
|
@ -9,7 +9,7 @@ class InterBackground native play version("2.5")
|
|||
}
|
||||
|
||||
// This is obsolete. Hopefully this was never used...
|
||||
struct PatchInfo play version("2.5")
|
||||
struct PatchInfo ui version("2.5")
|
||||
{
|
||||
Font mFont;
|
||||
deprecated("3.8") TextureID mPatch;
|
||||
|
@ -39,7 +39,7 @@ struct PatchInfo play version("2.5")
|
|||
};
|
||||
|
||||
|
||||
class StatusScreen abstract play version("2.5")
|
||||
class StatusScreen abstract ui version("2.5")
|
||||
{
|
||||
enum EValues
|
||||
{
|
||||
|
@ -801,6 +801,11 @@ class StatusScreen abstract play version("2.5")
|
|||
accelerateStage = 1;
|
||||
}
|
||||
|
||||
void checkForAccelerate()
|
||||
{
|
||||
// no longer used, but still needed for old content.
|
||||
}
|
||||
|
||||
// ====================================================================
|
||||
// Ticker
|
||||
// Purpose: Do various updates every gametic, for stats, animation,
|
||||
|
|
Loading…
Reference in a new issue