diff --git a/source/core/gamecvars.cpp b/source/core/gamecvars.cpp index 0c8c52ad4..737860d7d 100644 --- a/source/core/gamecvars.cpp +++ b/source/core/gamecvars.cpp @@ -97,6 +97,7 @@ CVARD(Bool, cl_bloodweapinterp, false, CVAR_ARCHIVE, "enable/disable Blood's wea CVARD(Bool, cl_bloodoldweapbalance, false, CVAR_ARCHIVE, "enable/disable legacy 1.0 weapon handling for Blood") CVARD(Bool, cl_loadingscreens, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG, "enable/disable loading screens for games") CVARD(Bool, cl_clampedpitch, true, CVAR_ARCHIVE, "clamp the view pitch to original ranges") +CVARD(Float, cl_exvertpanscale, 8.f, CVAR_ARCHIVE, "sets the scaling intensity for Exhumed's vert panning/slope tilting") CUSTOM_CVARD(Int, cl_dukepitchmode, 7, CVAR_ARCHIVE, "customise Duke's myriad of pitch options") { diff --git a/source/core/gamecvars.h b/source/core/gamecvars.h index 4826d9062..b82e01fff 100644 --- a/source/core/gamecvars.h +++ b/source/core/gamecvars.h @@ -44,6 +44,7 @@ EXTERN_CVAR(Bool, cl_bloodoldweapbalance) EXTERN_CVAR(Bool, cl_loadingscreens) EXTERN_CVAR(Bool, cl_clampedpitch) EXTERN_CVAR(Int, cl_dukepitchmode) +EXTERN_CVAR(Float, cl_exvertpanscale) EXTERN_CVAR(Bool, demorec_seeds_cvar) EXTERN_CVAR(Bool, demoplay_diffs) diff --git a/source/games/exhumed/src/player.cpp b/source/games/exhumed/src/player.cpp index 079834dac..dacc61614 100644 --- a/source/games/exhumed/src/player.cpp +++ b/source/games/exhumed/src/player.cpp @@ -1539,8 +1539,8 @@ static void doPlayerCameraEffects(DExhumedPlayer* const pPlayer, const double zD const auto nUnderwater = !!(pPlayerActor->sector()->Flag & kSectUnderwater); // Pitch tilting when player's Z changes (stairs, jumping, etc). - // This should amplified 8x, not 2x, but it feels very heavy. Add a CVAR? - doPlayerVertPanning(pPlayer, zDelta * 2 * cl_slopetilting); + // The default 8x amplification feels very heavy, so add a CVAR to control it. + doPlayerVertPanning(pPlayer, zDelta * cl_exvertpanscale * cl_slopetilting); // Roll tilting effect, either console or Quake-style. pPlayer->doRollInput(nUnderwater); diff --git a/wadsrc/static/menudef.txt b/wadsrc/static/menudef.txt index 92c8c0a73..d7c0380a6 100644 --- a/wadsrc/static/menudef.txt +++ b/wadsrc/static/menudef.txt @@ -1122,6 +1122,10 @@ OptionMenu "VideoOptions" protected Option "$DSPLYMNU_VOXELS", "r_voxels", "OnOff" Option "$DSPLYMNU_SHADOWS", "r_shadows", "OnOff" Option "$DSPLYMNU_SLOPETILT", "cl_slopetilting", "OnOff" + ifgame(Exhumed) + { + Slider "$DSPLYMNU_EXVERTPANNING", "cl_exvertpanscale", 0.5, 10, 0.1 + } Option "$GLPREFMNU_ENVIRONMENTMAPMIRROR", gl_mirror_envmap, "OnOff" ifnotgame(Blood, Exhumed) {