diff --git a/source/exhumed/src/engine.h b/source/exhumed/src/engine.h index d2b2858c9..1df63bba9 100644 --- a/source/exhumed/src/engine.h +++ b/source/exhumed/src/engine.h @@ -60,7 +60,6 @@ enum { kSectLava = 0x4000, }; -extern int ogameclock; extern int initx; extern int inity; extern int initz; @@ -114,10 +113,6 @@ void GrabMap(); void UpdateMap(); void DrawMap(); -// network - -extern short nNetMoveFrames; - // random void InitRandom(); diff --git a/source/exhumed/src/enginesubs.cpp b/source/exhumed/src/enginesubs.cpp index 80398e2d1..c4c68f87d 100644 --- a/source/exhumed/src/enginesubs.cpp +++ b/source/exhumed/src/enginesubs.cpp @@ -30,7 +30,6 @@ BEGIN_PS_NS void resettiming() { - ogameclock = -1; gameclock = 0; lastTic = -1; } diff --git a/source/exhumed/src/exhumed.cpp b/source/exhumed/src/exhumed.cpp index 95bcf9a75..34aea5d22 100644 --- a/source/exhumed/src/exhumed.cpp +++ b/source/exhumed/src/exhumed.cpp @@ -125,7 +125,6 @@ int nNetPlayerCount = 0; short nClockVal; short nRedTicks; -short bInMove; short nAlarmTicks; short nButtonColor; short nEnergyChan; @@ -150,7 +149,6 @@ short nCodeIndex = 0; //short nScreenWidth = 320; //short nScreenHeight = 200; -int moveframes; int flash; int totalmoves; @@ -466,14 +464,11 @@ void GameMove(void) // loc_120E9: totalmoves++; - moveframes--; } void GameTicker() { - bInMove = true; - int const currentTic = I_GetTime(); gameclock = I_GetBuildTime(); @@ -483,12 +478,9 @@ void GameTicker() } else { - while ((gameclock - ogameclock) >= 1 || !bInMove) + while (!EndLevel && currentTic - lastTic >= 1) { - ogameclock = I_GetBuildTime(); - - if (!((int)ogameclock & 3) && moveframes < 4) - moveframes++; + lastTic = currentTic; int lLocalButtons = GetLocalInput(); // shouldn't this be placed in localInput? PlayerInterruptKeys(); @@ -516,22 +508,14 @@ void GameTicker() sPlayerInput[nLocalPlayer].horizon = PlayerList[nLocalPlayer].q16horiz; - while (!EndLevel && currentTic - lastTic >= 1) - { - lastTic = currentTic; leveltime++; GameMove(); } - } if (nPlayerLives[nLocalPlayer] <= 0) { startmainmenu(); } } - bInMove = false; - - } -int32_t r_maxfpsoffset = 0; void ExitGame() @@ -740,7 +724,6 @@ static SavegameHelper sgh("exhumed", SV(nEnergyChan), SV(lCountDown), SV(nEnergyTowers), - SV(moveframes), SV(totalmoves), SV(nCurBodyNum), SV(nBodyTotal), diff --git a/source/exhumed/src/exhumed.h b/source/exhumed/src/exhumed.h index 960616354..47bfa58db 100644 --- a/source/exhumed/src/exhumed.h +++ b/source/exhumed/src/exhumed.h @@ -144,8 +144,6 @@ extern char sHollyStr[]; extern int selectedlevelnew; extern int GameAction; -extern int moveframes; - extern int nNetPlayerCount; extern int htimer; @@ -203,7 +201,6 @@ extern short nClockVal; extern short bSlipMode; extern int bVanilla; -extern short bInMove; #define POWERSLAVE (g_gameType & GAMEFLAG_POWERSLAVE) #define EXHUMED (g_gameType & GAMEFLAG_EXHUMED) diff --git a/source/exhumed/src/init.cpp b/source/exhumed/src/init.cpp index 3e296f755..0304d103d 100644 --- a/source/exhumed/src/init.cpp +++ b/source/exhumed/src/init.cpp @@ -38,8 +38,6 @@ enum kTagRamses = 61, }; -int ogameclock = 0; - int initx, inity, initz; short inita, initsect; @@ -197,8 +195,6 @@ void InitLevel(int level) totalmoves = 0; GrabPalette(); ResetMoveFifo(); - moveframes = 0; - bInMove = false; nPlayerDAng = 0; lPlayerXVel = 0; lPlayerYVel = 0; @@ -228,12 +224,6 @@ void InitNewGame() InitPlayerInventory(nPlayer); } - - nNetMoves = 0; - - // PINK SECTION - UpdateInputs(); - nNetMoves = 1; } void SetBelow(short nCurSector, short nBelowSector) diff --git a/source/exhumed/src/input.cpp b/source/exhumed/src/input.cpp index 91afdc49a..f51c828dd 100644 --- a/source/exhumed/src/input.cpp +++ b/source/exhumed/src/input.cpp @@ -30,8 +30,6 @@ BEGIN_PS_NS int WeaponToSend, BitsToSend; -int nNetMoves = 0; - short nInputStack = 0; short bStackNode[kMaxPlayers]; @@ -106,24 +104,6 @@ void SendInput() } -short nNetMoveFrames = 0; - -void UpdateInputs() -{ - nNetMoveFrames = moveframes; - - if (nNetPlayerCount) - { - //UpdateNetInputs(); - - nNetMoves++; - - if (!nNetMoves) { - nNetMoves++; - } - } -} - void CheckKeys() { // go to 3rd person view? diff --git a/source/exhumed/src/player.cpp b/source/exhumed/src/player.cpp index ea18c6f7e..becfac509 100644 --- a/source/exhumed/src/player.cpp +++ b/source/exhumed/src/player.cpp @@ -47,8 +47,8 @@ struct PlayerSave short nAngle; }; -fix16_t lPlayerXVel = 0; -fix16_t lPlayerYVel = 0; +int lPlayerXVel = 0; +int lPlayerYVel = 0; fix16_t nPlayerDAng = 0; short obobangle = 0, bobangle = 0; short bPlayerPan = 0; diff --git a/source/exhumed/src/ps_input.h b/source/exhumed/src/ps_input.h index 5350e5fb1..fbb73dfab 100644 --- a/source/exhumed/src/ps_input.h +++ b/source/exhumed/src/ps_input.h @@ -38,15 +38,12 @@ struct PlayerInput void InitInput(); -void UpdateInputs(); - void ClearSpaceBar(short nPlayer); int GetLocalInput(); extern PlayerInput sPlayerInput[]; extern InputPacket localInput; -extern int nNetMoves; extern int lLocalCodes; END_PS_NS diff --git a/source/exhumed/src/save.cpp b/source/exhumed/src/save.cpp index 59c4747fc..436b9623c 100644 --- a/source/exhumed/src/save.cpp +++ b/source/exhumed/src/save.cpp @@ -60,7 +60,6 @@ bool GameInterface::LoadGame(FSaveGameNode* sv) pSky->yscale = 65536; parallaxtype = 2; g_visibility = 2048; - ogameclock = gameclock; GameAction = 1000; if (currentLevel->levelNumber > 15)