From ccc746fbf40dd81d12a16a37410940311dd02d3e Mon Sep 17 00:00:00 2001 From: James R Date: Thu, 9 Apr 2020 17:21:30 -0700 Subject: [PATCH 1/8] Change netvars in replays --- src/command.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/command.c b/src/command.c index 625065120..6f3ccd7f6 100644 --- a/src/command.c +++ b/src/command.c @@ -1543,7 +1543,7 @@ static void CV_SetCVar(consvar_t *var, const char *value, boolean stealth) } // Only add to netcmd buffer if in a netgame, otherwise, just change it. - if (netgame || multiplayer) + if (netgame) { WRITEUINT16(p, var->netid); WRITESTRING(p, value); From 371cc18bf68dc194a2f74b18f4c26e9a9165962f Mon Sep 17 00:00:00 2001 From: Sally Cochenour Date: Sun, 12 Apr 2020 21:04:07 -0400 Subject: [PATCH 2/8] Update ALL finish line distances & positions, separately, before player thinkers happen, ensuring it's never inaccurate --- src/k_kart.c | 9 ++------- src/k_kart.h | 1 + src/p_tick.c | 22 ++++++++++++++++++++++ 3 files changed, 25 insertions(+), 7 deletions(-) diff --git a/src/k_kart.c b/src/k_kart.c index 7ad459ad1..dab36aaf9 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -6287,10 +6287,6 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd) void K_KartPlayerAfterThink(player_t *player) { - // Moved to afterthink, as at this point the players have had their distances to the finish line updated - // and this will correctly account for all players - K_KartUpdatePosition(player); - if (player->kartstuff[k_curshield] || player->kartstuff[k_invincibilitytimer] || (player->kartstuff[k_growshrinktimer] != 0 && player->kartstuff[k_growshrinktimer] % 5 == 4)) // 4 instead of 0 because this is afterthink! @@ -6607,7 +6603,7 @@ static boolean K_PlayerCloserToNextWaypoints(waypoint_t *const waypoint, player_ } /*-------------------------------------------------- - static void K_UpdateDistanceFromFinishLine(player_t *const player) + void K_UpdateDistanceFromFinishLine(player_t *const player) Updates the distance a player has to the finish line. @@ -6617,7 +6613,7 @@ static boolean K_PlayerCloserToNextWaypoints(waypoint_t *const waypoint, player_ Return:- None --------------------------------------------------*/ -static void K_UpdateDistanceFromFinishLine(player_t *const player) +void K_UpdateDistanceFromFinishLine(player_t *const player) { if ((player != NULL) && (player->mo != NULL)) { @@ -7167,7 +7163,6 @@ void K_MoveKartPlayer(player_t *player, boolean onground) boolean HOLDING_ITEM = (player->kartstuff[k_itemheld] || player->kartstuff[k_eggmanheld]); boolean NO_HYUDORO = (player->kartstuff[k_stolentimer] == 0 && player->kartstuff[k_stealingtimer] == 0); - K_UpdateDistanceFromFinishLine(player); player->pflags &= ~PF_HITFINISHLINE; if (!player->exiting) diff --git a/src/k_kart.h b/src/k_kart.h index 8dc5604b8..8f47b9780 100644 --- a/src/k_kart.h +++ b/src/k_kart.h @@ -59,6 +59,7 @@ void K_UpdateHnextList(player_t *player, boolean clean); void K_DropHnextList(player_t *player); void K_RepairOrbitChain(mobj_t *orbit); player_t *K_FindJawzTarget(mobj_t *actor, player_t *source); +void K_UpdateDistanceFromFinishLine(player_t *const player); boolean K_CheckPlayersRespawnColliding(INT32 playernum, fixed_t x, fixed_t y); INT16 K_GetKartTurnValue(player_t *player, INT16 turnvalue); INT32 K_GetKartDriftSparkValue(player_t *player); diff --git a/src/p_tick.c b/src/p_tick.c index d7359b307..43ca98416 100644 --- a/src/p_tick.c +++ b/src/p_tick.c @@ -616,6 +616,17 @@ void P_Ticker(boolean run) G_ReadDemoTiccmd(&players[i].cmd, i); } + // First loop: Ensure all players' distance to the finish line are all accurate + for (i = 0; i < MAXPLAYERS; i++) + if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo)) + K_UpdateDistanceFromFinishLine(&players[i]); + + // Second loop: Ensure all player positions reflect everyone's distances + for (i = 0; i < MAXPLAYERS; i++) + if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo)) + K_KartUpdatePosition(&players[i]); + + // OK! Now that we got all of that sorted, players can think! for (i = 0; i < MAXPLAYERS; i++) if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo)) P_PlayerThink(&players[i]); @@ -778,6 +789,17 @@ void P_PreTicker(INT32 frames) { P_MapStart(); + // First loop: Ensure all players' distance to the finish line are all accurate + for (i = 0; i < MAXPLAYERS; i++) + if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo)) + K_UpdateDistanceFromFinishLine(&players[i]); + + // Second loop: Ensure all player positions reflect everyone's distances + for (i = 0; i < MAXPLAYERS; i++) + if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo)) + K_KartUpdatePosition(&players[i]); + + // OK! Now that we got all of that sorted, players can think! for (i = 0; i < MAXPLAYERS; i++) if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo)) { From da953c9dae05fae848e2e61e4f81b993852bea94 Mon Sep 17 00:00:00 2001 From: Sally Cochenour Date: Sun, 12 Apr 2020 23:51:00 -0400 Subject: [PATCH 3/8] No more modulo bullshit in VERSION VERSION is the first number, SUBVERSION is the second number, and the third number burns in hell; we really don't need that precision --- src/d_clisrv.c | 12 ++++++------ src/doomdef.h | 2 +- src/mserv.c | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/d_clisrv.c b/src/d_clisrv.c index 084a6fd81..3347091a3 100644 --- a/src/d_clisrv.c +++ b/src/d_clisrv.c @@ -1880,7 +1880,7 @@ void CL_UpdateServerList(boolean internetsearch, INT32 room) { char version[8] = ""; #if VERSION > 0 || SUBVERSION > 0 - snprintf(version, sizeof (version), "%d.%d.%d", VERSION/100, VERSION%100, SUBVERSION); + snprintf(version, sizeof (version), "%d.%d", VERSION, SUBVERSION); #else strcpy(version, GetRevisionString()); #endif @@ -2355,8 +2355,8 @@ static void CL_ConnectToServer(boolean viams) gametypestr = Gametype_Names[num]; if (gametypestr) CONS_Printf(M_GetText("Gametype: %s\n"), gametypestr); - CONS_Printf(M_GetText("Version: %d.%d.%u\n"), serverlist[i].info.version/100, - serverlist[i].info.version%100, serverlist[i].info.subversion); + CONS_Printf(M_GetText("Version: %d.%d\n"), + serverlist[i].info.version, serverlist[i].info.subversion); } SL_ClearServerList(servernode); #endif @@ -3296,8 +3296,8 @@ static void Got_RemovePlayer(UINT8 **p, INT32 playernum); // called one time at init void D_ClientServerInit(void) { - DEBFILE(va("- - -== SRB2Kart v%d.%.2d.%d "VERSIONSTRING" debugfile ==- - -\n", - VERSION/100, VERSION%100, SUBVERSION)); + DEBFILE(va("- - -== SRB2Kart v%d.%d "VERSIONSTRING" debugfile ==- - -\n", + VERSION, SUBVERSION)); #ifndef NONET COM_AddCommand("getplayernum", Command_GetPlayerNum); @@ -3822,7 +3822,7 @@ static void HandleConnect(SINT8 node) SV_SendRefuse(node, M_GetText("You have been banned\nfrom the server")); else if (netbuffer->u.clientcfg.version != VERSION || netbuffer->u.clientcfg.subversion != SUBVERSION) - SV_SendRefuse(node, va(M_GetText("Different SRB2Kart versions cannot\nplay a netgame!\n(server version %d.%d.%d)"), VERSION/100, VERSION%100, SUBVERSION)); + SV_SendRefuse(node, va(M_GetText("Different SRB2Kart versions cannot\nplay a netgame!\n(server version %d.%d)"), VERSION, SUBVERSION)); else if (!cv_allownewplayer.value && node) SV_SendRefuse(node, M_GetText("The server is not accepting\njoins for the moment")); else if (D_NumPlayers() >= maxplayers) diff --git a/src/doomdef.h b/src/doomdef.h index ef7a2f8cb..2a67ce0e2 100644 --- a/src/doomdef.h +++ b/src/doomdef.h @@ -150,7 +150,7 @@ extern char logfilename[1024]; // most interface strings are ignored in development mode. // we use comprevision and compbranch instead. #else -#define VERSION 200 // Game version +#define VERSION 2 // Game version #define SUBVERSION 0 // more precise version number #define VERSIONSTRING "v2.0" #define VERSIONSTRINGW L"v2.0" diff --git a/src/mserv.c b/src/mserv.c index c7344b16a..12469928d 100644 --- a/src/mserv.c +++ b/src/mserv.c @@ -751,7 +751,7 @@ static INT32 AddToMasterServer(boolean firstadd) strcpy(info->name, cv_servername.string); M_Memcpy(&info->room, & room, sizeof (INT32)); #if VERSION > 0 || SUBVERSION > 0 - sprintf(info->version, "%d.%d.%d", VERSION/100, VERSION%100, SUBVERSION); + sprintf(info->version, "%d.%d", VERSION, SUBVERSION); #else // Trunk build, send revision info strcpy(info->version, GetRevisionString()); #endif @@ -789,7 +789,7 @@ static INT32 RemoveFromMasterSever(void) strcpy(info->ip, ""); strcpy(info->port, int2str(current_port)); strcpy(info->name, registered_server.name); - sprintf(info->version, "%d.%d.%d", VERSION/100, VERSION%100, SUBVERSION); + sprintf(info->version, "%d.%d", VERSION, SUBVERSION); msg.type = REMOVE_SERVER_MSG; msg.length = (UINT32)sizeof (msg_server_t); From e941749f4c96026912b3945d376187c1b26f2f4e Mon Sep 17 00:00:00 2001 From: Sally Cochenour Date: Wed, 15 Apr 2020 22:45:03 -0400 Subject: [PATCH 4/8] Move all of the item destroy sector code to one place --- src/p_mobj.c | 73 ++++++++++++++++++++++++++-------------------------- 1 file changed, 36 insertions(+), 37 deletions(-) diff --git a/src/p_mobj.c b/src/p_mobj.c index 2a12dcc7a..2838e9388 100644 --- a/src/p_mobj.c +++ b/src/p_mobj.c @@ -6153,7 +6153,7 @@ boolean P_IsKartItem(INT32 type) type == MT_JAWZ || type == MT_JAWZ_DUD || type == MT_JAWZ_SHIELD || type == MT_SSMINE || type == MT_SSMINE_SHIELD || type == MT_SINK || type == MT_SINK_SHIELD || - type == MT_SPB) + type == MT_SPB || type == MT_BALLHOG || type == MT_BUBBLESHIELDTRAP) return true; else return false; @@ -7175,6 +7175,41 @@ void P_MobjThinker(mobj_t *mobj) return; } #endif + + // Destroy items sector special + if (mobj->type == MT_BANANA || mobj->type == MT_EGGMANITEM + || mobj->type == MT_ORBINAUT || mobj->type == MT_BALLHOG + || mobj->type == MT_JAWZ || mobj->type == MT_JAWZ_DUD + || mobj->type == MT_SSMINE || mobj->type == MT_BUBBLESHIELDTRAP) + { + if (mobj->health > 0 && P_MobjTouchingSectorSpecial(mobj, 4, 7, true)) + { + if (mobj->type == MT_SSMINE + || mobj->type == MT_BUBBLESHIELDTRAP + || mobj->type == MT_BALLHOG) + { + S_StartSound(mobj, mobj->info->deathsound); + P_KillMobj(mobj, NULL, NULL); + } + else + { + // This Item Damage + if (mobj->eflags & MFE_VERTICALFLIP) + mobj->z -= mobj->height; + else + mobj->z += mobj->height; + + S_StartSound(mobj, mobj->info->deathsound); + P_KillMobj(mobj, NULL, NULL); + + P_SetObjectMomZ(mobj, 8*FRACUNIT, false); + P_InstaThrust(mobj, R_PointToAngle2(0, 0, mobj->momx, mobj->momy) + ANGLE_90, 16*FRACUNIT); + } + + return; + } + } + // if it's pushable, or if it would be pushable other than temporary disablement, use the // separate thinker if (mobj->flags & MF_PUSHABLE || (mobj->info->flags & MF_PUSHABLE && mobj->fuse)) @@ -7939,12 +7974,6 @@ void P_MobjThinker(mobj_t *mobj) { boolean grounded = P_IsObjectOnGround(mobj); - if (P_MobjTouchingSectorSpecial(mobj, 4, 7, true)) - { - P_RemoveMobj(mobj); - return; - } - if (mobj->flags2 & MF2_AMBUSH) { if (grounded && (mobj->flags & MF_NOCLIPTHING)) @@ -8015,12 +8044,6 @@ void P_MobjThinker(mobj_t *mobj) { mobj_t *ghost = P_SpawnGhostMobj(mobj); - if (P_MobjTouchingSectorSpecial(mobj, 4, 7, true)) - { - P_RemoveMobj(mobj); - return; - } - if (mobj->target && !P_MobjWasRemoved(mobj->target) && mobj->target->player) { ghost->color = mobj->target->player->skincolor; @@ -8045,12 +8068,6 @@ void P_MobjThinker(mobj_t *mobj) { boolean grounded = P_IsObjectOnGround(mobj); - if (P_MobjTouchingSectorSpecial(mobj, 4, 7, true)) - { - P_RemoveMobj(mobj); - return; - } - if (mobj->flags2 & MF2_AMBUSH) { if (grounded && (mobj->flags & MF_NOCLIPTHING)) @@ -8124,12 +8141,6 @@ void P_MobjThinker(mobj_t *mobj) case MT_BANANA: mobj->friction = ORIG_FRICTION/4; - if (P_MobjTouchingSectorSpecial(mobj, 4, 7, true)) - { - P_RemoveMobj(mobj); - return; - } - if (mobj->momx || mobj->momy) { mobj_t *ghost = P_SpawnGhostMobj(mobj); @@ -8159,12 +8170,6 @@ void P_MobjThinker(mobj_t *mobj) mobj_t *ghost = P_SpawnGhostMobj(mobj); ghost->fuse = 3; - if (P_MobjTouchingSectorSpecial(mobj, 4, 7, true)) - { - P_RemoveMobj(mobj); - return; - } - if (mobj->target && !P_MobjWasRemoved(mobj->target) && mobj->target->player) { ghost->color = mobj->target->player->skincolor; @@ -8197,12 +8202,6 @@ void P_MobjThinker(mobj_t *mobj) mobj->threshold--; break; case MT_SSMINE: - if (P_MobjTouchingSectorSpecial(mobj, 4, 7, true)) - { - P_RemoveMobj(mobj); - return; - } - if (mobj->target && mobj->target->player) mobj->color = mobj->target->player->skincolor; else From 263c31f5df8f4a47c233d7fa4687f1917b4688a5 Mon Sep 17 00:00:00 2001 From: lachwright Date: Tue, 21 Apr 2020 02:38:08 +0800 Subject: [PATCH 5/8] Improve camera tilt --- src/p_user.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/src/p_user.c b/src/p_user.c index 16038fade..3a5300f42 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -7411,7 +7411,7 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall if (mo->standingslope) { - pitch = (angle_t)FixedMul(P_ReturnThrustX(mo, player->frameangle - mo->standingslope->xydirection, FRACUNIT), (fixed_t)mo->standingslope->zangle); + pitch = (angle_t)FixedMul(P_ReturnThrustX(mo, thiscam->angle - mo->standingslope->xydirection, FRACUNIT), (fixed_t)mo->standingslope->zangle); if (mo->eflags & MFE_VERTICALFLIP) { if (pitch >= ANGLE_180) @@ -7476,9 +7476,15 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall pviewheight = FixedMul(32<scale); if (mo->eflags & MFE_VERTICALFLIP) - z = mo->z + mo->height - pviewheight - camheight + distz; + { + distz = min(-height, distz); + z = mo->z + mo->height - pviewheight + distz; + } else - z = mo->z + pviewheight + camheight + distz; + { + distz = max(height, distz); + z = mo->z + pviewheight + distz; + } #ifndef NOCLIPCAM // Disable all z-clipping for noclip cam // move camera down to move under lower ceilings @@ -7724,13 +7730,13 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall { angle = R_PointToAngle2(0, thiscam->z + thiscam->height, dist, mo->z + mo->height - P_GetPlayerHeight(player)); if (thiscam->pitch < ANGLE_180 && thiscam->pitch > angle) - angle = thiscam->pitch; + angle += (thiscam->pitch - angle)/2; } else { angle = R_PointToAngle2(0, thiscam->z, dist, mo->z + P_GetPlayerHeight(player)); if (thiscam->pitch >= ANGLE_180 && thiscam->pitch < angle) - angle = thiscam->pitch; + angle -= (angle - thiscam->pitch)/2; } if (player->playerstate != PST_DEAD && !((player->pflags & PF_NIGHTSMODE) && player->exiting)) From 6905cfb0643df798cd53649ef40b49153378ced8 Mon Sep 17 00:00:00 2001 From: lachwright Date: Tue, 21 Apr 2020 03:30:45 +0800 Subject: [PATCH 6/8] Revert camtilt splitscreen hacks --- src/p_user.c | 4 ++-- src/r_main.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/p_user.c b/src/p_user.c index 3a5300f42..46b0a4f26 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -7434,8 +7434,8 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall else distxy = dist; distz = -FixedMul(dist, FINESINE((pitch>>ANGLETOFINESHIFT) & FINEMASK)); - if (r_splitscreen == 1) // 2 player is weird, this helps keep players on screen - distz = 3*distz/5; + //if (r_splitscreen == 1) // 2 player is weird, this helps keep players on screen + //distz = 3*distz/5; x = mo->x - FixedMul(FINECOSINE((angle>>ANGLETOFINESHIFT) & FINEMASK), distxy); y = mo->y - FixedMul(FINESINE((angle>>ANGLETOFINESHIFT) & FINEMASK), distxy); diff --git a/src/r_main.c b/src/r_main.c index 5afda93f7..10ba4d6a8 100644 --- a/src/r_main.c +++ b/src/r_main.c @@ -841,7 +841,7 @@ static void R_SetupFreelook(void) // clip it in the case we are looking a hardware 90 degrees full aiming // (lmps, network and use F12...) G_SoftwareClipAimingPitch((INT32 *)&aimingangle); - dy = AIMINGTODY(aimingangle) * viewheight/BASEVIDHEIGHT; + dy = AIMINGTODY(aimingangle) * viewwidth/BASEVIDWIDTH; yslope = &yslopetab[viewheight*8 - (viewheight/2 + dy)]; } centery = (viewheight/2) + dy; From c92634c71e4bba4c00301c909292175c2050b23a Mon Sep 17 00:00:00 2001 From: lachwright Date: Tue, 21 Apr 2020 05:24:48 +0800 Subject: [PATCH 7/8] Make lookback instantaneous --- src/p_user.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/src/p_user.c b/src/p_user.c index 46b0a4f26..fe7082990 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -7157,13 +7157,14 @@ void P_ResetCamera(player_t *player, camera_t *thiscam) boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcalled) { - static UINT8 lookbackdelay[4] = {0,0,0,0}; + static boolean lookbackactive[MAXSPLITSCREENPLAYERS]; + static UINT8 lookbackdelay[MAXSPLITSCREENPLAYERS]; UINT8 num; angle_t angle = 0, focusangle = 0, focusaiming = 0, pitch = 0; fixed_t x, y, z, dist, distxy, distz, height, viewpointx, viewpointy, camspeed, camdist, camheight, pviewheight; fixed_t pan, xpan, ypan; INT32 camrotate; - boolean camstill, lookback; + boolean camstill, lookback, lookbackdown; UINT8 timeover; mobj_t *mo; fixed_t f1, f2; @@ -7343,15 +7344,19 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall camstill = true; else if (lookback || lookbackdelay[num]) // SRB2kart - Camera flipper { +#define MAXLOOKBACKDELAY 2 camspeed = FRACUNIT; if (lookback) { camrotate += 180; - lookbackdelay[num] = 2; + lookbackdelay[num] = MAXLOOKBACKDELAY; } else lookbackdelay[num]--; } + lookbackdown = (lookbackdelay[num] == MAXLOOKBACKDELAY) != lookbackactive[num]; + lookbackactive[num] = (lookbackdelay[num] == MAXLOOKBACKDELAY); +#undef MAXLOOKBACKDELAY if (mo->eflags & MFE_VERTICALFLIP) camheight += thiscam->height; @@ -7434,8 +7439,6 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall else distxy = dist; distz = -FixedMul(dist, FINESINE((pitch>>ANGLETOFINESHIFT) & FINEMASK)); - //if (r_splitscreen == 1) // 2 player is weird, this helps keep players on screen - //distz = 3*distz/5; x = mo->x - FixedMul(FINECOSINE((angle>>ANGLETOFINESHIFT) & FINEMASK), distxy); y = mo->y - FixedMul(FINESINE((angle>>ANGLETOFINESHIFT) & FINEMASK), distxy); @@ -7779,6 +7782,9 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall thiscam->aiming = ANGLE_22h; } + if (lookbackdown) + P_MoveChaseCamera(player, thiscam, false); + return (x == thiscam->x && y == thiscam->y && z == thiscam->z && angle == thiscam->aiming); } From dd126494b3b7bfc74bca904c2a9ec16743f13de6 Mon Sep 17 00:00:00 2001 From: lachwright Date: Wed, 22 Apr 2020 22:59:57 +0800 Subject: [PATCH 8/8] [Everyone disliked that.] (revert camera zoom) --- src/p_user.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/p_user.c b/src/p_user.c index fe7082990..5358df1fe 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -7161,7 +7161,7 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall static UINT8 lookbackdelay[MAXSPLITSCREENPLAYERS]; UINT8 num; angle_t angle = 0, focusangle = 0, focusaiming = 0, pitch = 0; - fixed_t x, y, z, dist, distxy, distz, height, viewpointx, viewpointy, camspeed, camdist, camheight, pviewheight; + fixed_t x, y, z, dist, distxy, distz, viewpointx, viewpointy, camspeed, camdist, camheight, pviewheight; fixed_t pan, xpan, ypan; INT32 camrotate; boolean camstill, lookback, lookbackdown; @@ -7399,8 +7399,6 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall thiscam->angle = angle; } - height = camheight; - // sets ideal cam pos dist = camdist; @@ -7409,10 +7407,7 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall dist += abs(thiscam->momz)/4; if (player->karthud[khud_boostcam]) - { dist -= FixedMul(11*dist/16, player->karthud[khud_boostcam]); - height -= FixedMul(height, player->karthud[khud_boostcam]); - } if (mo->standingslope) { @@ -7480,12 +7475,12 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall if (mo->eflags & MFE_VERTICALFLIP) { - distz = min(-height, distz); + distz = min(-camheight, distz); z = mo->z + mo->height - pviewheight + distz; } else { - distz = max(height, distz); + distz = max(camheight, distz); z = mo->z + pviewheight + distz; }