diff --git a/CHANGELOG.md b/CHANGELOG.md index 2e5671a4f..2efdef43d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -41,11 +41,13 @@ ## Bug Fixes +- **_View Height_ increments not being applied immediately** - **Further corrected view pitch as FOV changes** - **Disabled teleport-to-Automap-pointer during non-Casual Play** - **Excess speed when airborne with noclip enabled** [thanks @kitchen-ace] - **Blazing door sound fix not applying to Boom doors** - **Teleporter Zoom and BFG "explosion" shake affecting all players in multiplayer** - **Explosion shake being stopped by the menu during demo playback and netgames** +- **View snapping when teleporting to Automap pointer while crouching** - **Fixed a demo desync** caused by a failed weapon autoswitch when picking up ammo - **Tweaked dark menu background and Automap overlay algorithm** (fixes very low values) diff --git a/src/am_map.c b/src/am_map.c index 272a94ac8..0d9c45cac 100644 --- a/src/am_map.c +++ b/src/am_map.c @@ -999,7 +999,7 @@ boolean AM_Responder P_TeleportMove(mo, (m_x+m_w/2)<z = mo->floorz; - plr->viewz = mo->z + plr->viewheight; + plr->viewz = mo->z + plr->viewheight - plr->crouchoffset; if (fancy_teleport) { R_SetFOVFX(FOVFX_TELEPORT); // Teleporter zoom diff --git a/src/m_menu.c b/src/m_menu.c index 5cafd8f85..aacc2975e 100644 --- a/src/m_menu.c +++ b/src/m_menu.c @@ -4880,6 +4880,17 @@ setup_menu_t gen_settings5[] = { // General Settings screen5 // [Nugget] /----------------------------------------------------------------- +static void M_ChangeViewHeight(void) +{ + static int oldviewheight = 0; + + for (int i = 0; i < MAXPLAYERS; i++) + if (playeringame[i] && players[i].playerstate == PST_LIVE) + { players[i].viewheight += (viewheight_value - oldviewheight) * FRACUNIT; } + + oldviewheight = viewheight_value; +} + static const char *impact_pitch_str[] = { "Off", "Fall", "Damage", "Both", NULL }; @@ -4899,7 +4910,7 @@ setup_menu_t gen_settings6[] = { {"Nugget - View", S_SKIP|S_TITLE, m_null, M_X, M_Y + gen6_title2 * M_SPC}, {"Field of View", S_NUM |S_STRICT, m_null, M_X, M_Y + gen6_fov * M_SPC, {"fov"}, 0, M_SetFOV}, - {"View Height", S_NUM |S_STRICT, m_null, M_X, M_Y + gen6_viewheight * M_SPC, {"viewheight_value"}}, + {"View Height", S_NUM |S_STRICT, m_null, M_X, M_Y + gen6_viewheight * M_SPC, {"viewheight_value"}, 0, M_ChangeViewHeight}, {"View Bobbing Percentage", S_NUM, m_null, M_X, M_Y + gen6_viewbobbing * M_SPC, {"view_bobbing_percentage"}}, {"Impact Pitch", S_CHOICE|S_STRICT, m_null, M_X, M_Y + gen6_impactpitch * M_SPC, {"impact_pitch"}, 0, NULL, impact_pitch_str}, {"Explosion Shake Effect", S_YESNO |S_STRICT, m_null, M_X, M_Y + gen6_expshake * M_SPC, {"explosion_shake"}},