diff --git a/source/sw/src/draw.cpp b/source/sw/src/draw.cpp index ecf4d8fdd..56c526dff 100644 --- a/source/sw/src/draw.cpp +++ b/source/sw/src/draw.cpp @@ -1645,7 +1645,7 @@ drawscreen(PLAYERp pp, double smoothratio) // Interpolate the player's angle while on a sector object, just like VoidSW. // This isn't needed for the turret as it was fixable, but moving sector objects are problematic. - if (cl_syncinput || pp != Player+myconnectindex || (!cl_syncinput && pp->sop && !TEST(pp->Flags2, PF2_INPUT_CAN_TURN_TURRET))) + if (cl_syncinput || pp != Player+myconnectindex) { fixed_t dang = IntToFixed(1024); fixed_t oang = camerapp->oq16ang + camerapp->oq16look_ang; diff --git a/source/sw/src/player.cpp b/source/sw/src/player.cpp index 32d125cb1..4355a6161 100644 --- a/source/sw/src/player.cpp +++ b/source/sw/src/player.cpp @@ -134,6 +134,9 @@ PLAYER Player[MAX_SW_PLAYERS_REG + 1]; short NormalVisibility; +// bool for determining whether game has set cl_syncinput or not. +static bool gamesetinput = false; + int InitBloodSpray(int16_t SpriteNum, bool dogib, short velocity); SPRITEp FindNearSprite(SPRITEp sp, short stat); @@ -2832,6 +2835,9 @@ DoPlayerMoveVehicle(PLAYERp pp) PlaySOsound(pp->sop->mid_sector,SO_IDLE_SOUND); } + // force synchronised input here for now. + gamesetinput = cl_syncinput = true; + if (PLAYER_MOVING(pp) == 0) RESET(pp->Flags, PF_PLAYER_MOVED); else @@ -7296,6 +7302,12 @@ domovethings(void) RESET(pp->Flags2, PF2_INPUT_CAN_AIM|PF2_INPUT_CAN_TURN_GENERAL|PF2_INPUT_CAN_TURN_VEHICLE|PF2_INPUT_CAN_TURN_TURRET); resetinputhelpers(pp); + // disable synchronised input if set by game. + if (gamesetinput) + { + gamesetinput = cl_syncinput = false; + } + if (pp->DoPlayerAction) pp->DoPlayerAction(pp); UpdatePlayerSprite(pp);