mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-26 22:11:43 +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);
|
cs.Create(runner);
|
||||||
if (!ScreenJobValidate())
|
if (!ScreenJobValidate())
|
||||||
{
|
{
|
||||||
runner->Destroy();
|
DeleteScreenJob();
|
||||||
runner = nullptr;
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (sysCallbacks.StartCutscene) sysCallbacks.StartCutscene(flags & SJ_BLOCKUI);
|
if (sysCallbacks.StartCutscene) sysCallbacks.StartCutscene(flags & SJ_BLOCKUI);
|
||||||
}
|
}
|
||||||
catch (...)
|
catch (...)
|
||||||
{
|
{
|
||||||
if (runner) runner->Destroy();
|
DeleteScreenJob();
|
||||||
runner = nullptr;
|
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -3385,6 +3385,7 @@ static int D_DoomMain_Internal (void)
|
||||||
|
|
||||||
R_ParseTrnslate();
|
R_ParseTrnslate();
|
||||||
PClassActor::StaticInit ();
|
PClassActor::StaticInit ();
|
||||||
|
Job_Init();
|
||||||
|
|
||||||
// [GRB] Initialize player class list
|
// [GRB] Initialize player class list
|
||||||
SetupPlayerClasses ();
|
SetupPlayerClasses ();
|
||||||
|
|
|
@ -1190,6 +1190,7 @@ void G_Ticker ()
|
||||||
break;
|
break;
|
||||||
case ga_intermission:
|
case ga_intermission:
|
||||||
gamestate = GS_CUTSCENE;
|
gamestate = GS_CUTSCENE;
|
||||||
|
gameaction = ga_nothing;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -956,8 +956,7 @@ void RunIntermission(DIntermissionController* intermissionScreen, DObject* statu
|
||||||
|
|
||||||
if (!ScreenJobValidate())
|
if (!ScreenJobValidate())
|
||||||
{
|
{
|
||||||
runner->Destroy();
|
DeleteScreenJob();
|
||||||
runner = nullptr;
|
|
||||||
if (completion) completion(false);
|
if (completion) completion(false);
|
||||||
completion = nullptr;
|
completion = nullptr;
|
||||||
return;
|
return;
|
||||||
|
@ -1010,7 +1009,11 @@ void G_DoCompleted (void)
|
||||||
}
|
}
|
||||||
bool endgame = intermissionScreen && intermissionScreen->mEndGame;
|
bool endgame = intermissionScreen && intermissionScreen->mEndGame;
|
||||||
intermissionScreen = primaryLevel->CreateIntermission();
|
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;
|
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 bool OnEvent(InputEvent evt) { return controller.Responder(evt); }
|
||||||
override void OnTick() { if (!controller.Ticker()) jobstate = finished; }
|
override void OnTick() { if (!controller.Ticker()) jobstate = finished; }
|
||||||
|
@ -37,9 +41,10 @@ class StatusScreenJob : SkippableScreenJob
|
||||||
{
|
{
|
||||||
StatusScreen controller;
|
StatusScreen controller;
|
||||||
|
|
||||||
void Init(StatusScreen scr)
|
ScreenJob Init(StatusScreen scr)
|
||||||
{
|
{
|
||||||
controller = scr;
|
controller = scr;
|
||||||
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
override void OnTick() { controller.Ticker(); if (controller.CurState == StatusScreen.LeavingIntermission) jobstate = finished; }
|
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!
|
// 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 static InterBackground Create(wbstartstruct wbst);
|
||||||
native virtual bool LoadBackground(bool isenterpic);
|
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...
|
// This is obsolete. Hopefully this was never used...
|
||||||
struct PatchInfo play version("2.5")
|
struct PatchInfo ui version("2.5")
|
||||||
{
|
{
|
||||||
Font mFont;
|
Font mFont;
|
||||||
deprecated("3.8") TextureID mPatch;
|
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
|
enum EValues
|
||||||
{
|
{
|
||||||
|
@ -801,6 +801,11 @@ class StatusScreen abstract play version("2.5")
|
||||||
accelerateStage = 1;
|
accelerateStage = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void checkForAccelerate()
|
||||||
|
{
|
||||||
|
// no longer used, but still needed for old content.
|
||||||
|
}
|
||||||
|
|
||||||
// ====================================================================
|
// ====================================================================
|
||||||
// Ticker
|
// Ticker
|
||||||
// Purpose: Do various updates every gametic, for stats, animation,
|
// Purpose: Do various updates every gametic, for stats, animation,
|
||||||
|
|
Loading…
Reference in a new issue