diff --git a/source/blood/src/player.cpp b/source/blood/src/player.cpp index 42f8986a0..0ea768cea 100644 --- a/source/blood/src/player.cpp +++ b/source/blood/src/player.cpp @@ -1316,18 +1316,6 @@ void UpdatePlayerSpriteAngle(PLAYER *pPlayer) pPlayer->angold = pSprite->ang = pPlayer->angle.ang.asbuild(); } -//--------------------------------------------------------------------------- -// -// Unsynchronised input helpers. -// -//--------------------------------------------------------------------------- - -static void resetinputhelpers(PLAYER* pPlayer) -{ - pPlayer->horizon.resetadjustment(); - pPlayer->angle.resetadjustment(); -} - void ProcessInput(PLAYER *pPlayer) { enum @@ -1338,7 +1326,8 @@ void ProcessInput(PLAYER *pPlayer) Item_JumpBoots = 3 }; - resetinputhelpers(pPlayer); + pPlayer->horizon.resetadjustment(); + pPlayer->angle.resetadjustment(); spritetype *pSprite = pPlayer->pSprite; XSPRITE *pXSprite = pPlayer->pXSprite; diff --git a/source/games/duke/src/funct.h b/source/games/duke/src/funct.h index dde5708eb..0ff6ccc65 100644 --- a/source/games/duke/src/funct.h +++ b/source/games/duke/src/funct.h @@ -242,7 +242,6 @@ int* animateptr(int i); void backuppos(player_struct* p, bool noclipping = false); void backupweapon(player_struct* p); -void resetinputhelpers(player_struct* p); void checkhardlanding(player_struct* p); void playerweaponsway(player_struct* p, spritetype* s); diff --git a/source/games/duke/src/player.cpp b/source/games/duke/src/player.cpp index e1d15b27f..e631ace85 100644 --- a/source/games/duke/src/player.cpp +++ b/source/games/duke/src/player.cpp @@ -844,18 +844,6 @@ void backupweapon(player_struct* p) // //--------------------------------------------------------------------------- -void resetinputhelpers(player_struct* p) -{ - p->horizon.resetadjustment(); - p->angle.resetadjustment(); -} - -//--------------------------------------------------------------------------- -// -// -// -//--------------------------------------------------------------------------- - void checkhardlanding(player_struct* p) { if (p->hard_landing > 0) diff --git a/source/games/duke/src/player_d.cpp b/source/games/duke/src/player_d.cpp index 8001f9f03..66ccffd0f 100644 --- a/source/games/duke/src/player_d.cpp +++ b/source/games/duke/src/player_d.cpp @@ -2668,7 +2668,8 @@ void processinput_d(int snum) pi = p->i; s = &sprite[pi]; - resetinputhelpers(p); + p->horizon.resetadjustment(); + p->angle.resetadjustment(); actions = PlayerInputBits(snum, SB_ALL); diff --git a/source/games/duke/src/player_r.cpp b/source/games/duke/src/player_r.cpp index 0b688a2cc..cbbf52ffa 100644 --- a/source/games/duke/src/player_r.cpp +++ b/source/games/duke/src/player_r.cpp @@ -3455,7 +3455,8 @@ void processinput_r(int snum) pi = p->i; s = &sprite[pi]; - resetinputhelpers(p); + p->horizon.resetadjustment(); + p->angle.resetadjustment(); actions = PlayerInputBits(snum, SB_ALL); diff --git a/source/sw/src/player.cpp b/source/sw/src/player.cpp index 818e72982..8cd57ecae 100644 --- a/source/sw/src/player.cpp +++ b/source/sw/src/player.cpp @@ -1065,18 +1065,6 @@ STATEp sg_PlayerNinjaFly[] = ///////////////////////////////////////////////////////////////////////////// -//--------------------------------------------------------------------------- -// -// Unsynchronised input helper. -// -//--------------------------------------------------------------------------- - -static void resetinputhelpers(PLAYERp pp) -{ - pp->angle.resetadjustment(); - pp->horizon.resetadjustment(); -} - void DoPlayerSpriteThrow(PLAYERp pp) { @@ -7297,7 +7285,8 @@ domovethings(void) // Reset flags used while tying input to framerate RESET(pp->Flags2, PF2_INPUT_CAN_AIM|PF2_INPUT_CAN_TURN_GENERAL|PF2_INPUT_CAN_TURN_VEHICLE|PF2_INPUT_CAN_TURN_TURRET); - resetinputhelpers(pp); + pp->horizon.resetadjustment(); + pp->angle.resetadjustment(); // disable synchronised input if set by game. if (gamesetinput)