- timer code fixes.

This commit is contained in:
Christoph Oelckers 2021-05-24 20:34:01 +02:00
parent 1a9755b719
commit d994369fd0
4 changed files with 3 additions and 6 deletions

View file

@ -797,7 +797,9 @@ DEFINE_ACTION_FUNCTION(_MoviePlayer, Create)
DEFINE_ACTION_FUNCTION(_MoviePlayer, Start)
{
PARAM_SELF_STRUCT_PROLOGUE(MoviePlayer);
I_FreezeTime(true);
self->Start();
I_FreezeTime(false);
return 0;
}

View file

@ -59,7 +59,6 @@ PClass* runnerclass;
PType* runnerclasstype;
CompletionFunc completion;
static int ticks;
int intermissiondelay;
//=============================================================================
//
@ -287,6 +286,7 @@ bool ScreenJobValidate()
VMValue parm[] = { runner };
VMReturn ret(&res);
VMCall(func, parm, 1, &ret, 1);
I_ResetFrameTime();
return res;
}
}
@ -315,8 +315,6 @@ bool StartCutscene(CutsceneDef& cs, int flags, const CompletionFunc& completion_
runner = nullptr;
return false;
}
if (flags & SJ_DELAY) intermissiondelay = 10; // need to wait a bit at the start to let the timer catch up.
else intermissiondelay = 0;
if (sysCallbacks.StartCutscene) sysCallbacks.StartCutscene(flags & SJ_BLOCKUI);
}
catch (...)

View file

@ -17,7 +17,6 @@ void Job_Init();
enum
{
SJ_BLOCKUI = 1,
SJ_DELAY = 2,
};
struct CutsceneDef
@ -51,7 +50,6 @@ DObject* CreateRunner(bool clearbefore = true);
void AddGenericVideo(DObject* runner, const FString& fn, int soundid, int fps);
extern int intermissiondelay;
extern DObject* runner;
extern PClass* runnerclass;
extern PType* runnerclasstype;

View file

@ -26,4 +26,3 @@ enum gamestate_t : int
extern gamestate_t gamestate;
extern int intermissiondelay;