From f8210ef8eebe566b5e8b045e9eb36431bc1437e5 Mon Sep 17 00:00:00 2001 From: Mitchell Richters Date: Mon, 21 Sep 2020 20:44:02 +1000 Subject: [PATCH] - Exhumed: Clean out some old bools regarding old panning code. --- source/exhumed/src/exhumed.cpp | 4 ---- source/exhumed/src/input.cpp | 3 --- source/exhumed/src/player.cpp | 11 ++--------- 3 files changed, 2 insertions(+), 16 deletions(-) diff --git a/source/exhumed/src/exhumed.cpp b/source/exhumed/src/exhumed.cpp index 842839342..8cd209610 100644 --- a/source/exhumed/src/exhumed.cpp +++ b/source/exhumed/src/exhumed.cpp @@ -50,10 +50,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. BEGIN_PS_NS -extern short bPlayerPan; -extern short bLockPan; - - static MapRecord* NextMap; void uploadCinemaPalettes(); diff --git a/source/exhumed/src/input.cpp b/source/exhumed/src/input.cpp index be6bcdf4f..4504fe808 100644 --- a/source/exhumed/src/input.cpp +++ b/source/exhumed/src/input.cpp @@ -25,9 +25,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. BEGIN_PS_NS -extern short bPlayerPan; -extern short bLockPan; - static int turn; static int counter; diff --git a/source/exhumed/src/player.cpp b/source/exhumed/src/player.cpp index f8b957127..fa2293d4b 100644 --- a/source/exhumed/src/player.cpp +++ b/source/exhumed/src/player.cpp @@ -52,8 +52,6 @@ struct PlayerSave int lPlayerXVel = 0; int lPlayerYVel = 0; short obobangle = 0, bobangle = 0; -short bPlayerPan = 0; -short bLockPan = 0; static actionSeq ActionSeq[] = { {18, 0}, {0, 0}, {9, 0}, {27, 0}, {63, 0}, @@ -460,9 +458,6 @@ void RestartPlayer(short nPlayer) SetMagicFrame(); RestoreGreenPal(); - - bPlayerPan = 0; - bLockPan = 0; } sprintf(playerNames[nPlayer], "JOE%d", nPlayer); @@ -1106,8 +1101,8 @@ void FuncPlayer(int a, int nDamage, int nRun) zVelB = -zVelB; } - if (zVelB > 512 && !bLockPan) { - playerSetHoriz(&PlayerList[nPlayer].q16horiz, &PlayerList[nPlayer].horizTarget, 100); + if (zVelB > 512 && PlayerList[nPlayer].q16angle != IntToFixed(100) && !(sPlayerInput[nPlayer].actions & (SB_AIM_UP|SB_AIM_DOWN))) { + sPlayerInput[nPlayer].actions |= SB_CENTERVIEW; } } @@ -2852,8 +2847,6 @@ static SavegameHelper sgh("player", SV(lPlayerYVel), SV(obobangle), SV(bobangle), - SV(bPlayerPan), - SV(bLockPan), SV(nStandHeight), SV(PlayerCount), SV(nNetStartSprites),