mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-24 10:40:46 +00:00
Reset timer after closing menu
This commit is contained in:
parent
5a19f5cd4d
commit
1dbc06bfa0
3 changed files with 10 additions and 6 deletions
|
@ -1210,11 +1210,11 @@ void bail2dos(const char *fmt, ...)
|
|||
|
||||
void faketimerhandler()
|
||||
{
|
||||
if (((int)totalclock < ototalclock + 1) || bInMove)
|
||||
if ((totalclock < ototalclock + 1) || bInMove)
|
||||
return;
|
||||
ototalclock++;
|
||||
ototalclock = ototalclock + 1;
|
||||
|
||||
if (!(ototalclock&3) && moveframes < 4)
|
||||
if (!((int)ototalclock&3) && moveframes < 4)
|
||||
moveframes++;
|
||||
|
||||
PlayerInterruptKeys();
|
||||
|
@ -2946,6 +2946,7 @@ LOOP3:
|
|||
CONTROL_ClearButton(gamefunc_Escape);
|
||||
// MENU2:
|
||||
CONTROL_BindsEnabled = 0;
|
||||
bInMove = kTrue;
|
||||
nMenu = menu_Menu(1);
|
||||
|
||||
switch (nMenu)
|
||||
|
@ -2970,6 +2971,9 @@ LOOP3:
|
|||
}
|
||||
break;
|
||||
}
|
||||
|
||||
totalclock = ototalclock = tclocks;
|
||||
bInMove = kFalse;
|
||||
CONTROL_BindsEnabled = 1;
|
||||
RefreshStatus();
|
||||
}
|
||||
|
|
|
@ -32,7 +32,7 @@ enum
|
|||
kTagRamses = 61,
|
||||
};
|
||||
|
||||
int ototalclock = 0;
|
||||
ClockTicks ototalclock = 0;
|
||||
|
||||
int initx, inity, initz;
|
||||
short inita, initsect;
|
||||
|
@ -418,7 +418,7 @@ void ResetEngine()
|
|||
resettiming();
|
||||
|
||||
totalclock = 0;
|
||||
ototalclock = (int)totalclock;
|
||||
ototalclock = totalclock;
|
||||
localclock = (int)totalclock;
|
||||
|
||||
numframes = 0;
|
||||
|
|
|
@ -11,7 +11,7 @@ enum {
|
|||
kSectLava = 0x4000,
|
||||
};
|
||||
|
||||
extern int ototalclock;
|
||||
extern ClockTicks ototalclock;
|
||||
|
||||
extern int initx;
|
||||
extern int inity;
|
||||
|
|
Loading…
Reference in a new issue