dont constantly fetch lookback joyaxis in p_ticker if replay recording is enabled
minuscule optimization lul
This commit is contained in:
1 parent
8cab07a4b2
commit
16e0c6f0f6
1 file changed
+4
-3
+4
-3
@@ -728,11 +728,12 @@ void P_Ticker(boolean run)
|
||||
|
||||
if (cv_recordmultiplayerdemos.value)
|
||||
{
|
||||
const INT32 axis = JoyAxis(AXISLOOKBACK, 1);
|
||||
|
||||
if (demo.savemode == DSM_NOTSAVING || demo.savemode == DSM_WILLAUTOSAVE)
|
||||
if (demo.savebutton && demo.savebutton + 3*TICRATE < leveltime && (InputDown(gc_lookback, 1) || (cv_usejoystick[0].value && axis > 0)))
|
||||
{
|
||||
const INT32 axis = cv_usejoystick[0].value ? JoyAxis(AXISLOOKBACK, 1) : -1;
|
||||
if (demo.savebutton && demo.savebutton + 3*TICRATE < leveltime && (InputDown(gc_lookback, 1) || (axis > 0)))
|
||||
demo.savemode = DSM_TITLEENTRY;
|
||||
}
|
||||
|
||||
// if there are no players left at all, stop demo recording
|
||||
// Demos that that dont have any players crash during playback, which can happen with dedicated servers
|
||||
|
||||
Reference in new issue
Block a user