diff --git a/source/core/gameinput.h b/source/core/gameinput.h index 241591b91..fa6ff6390 100644 --- a/source/core/gameinput.h +++ b/source/core/gameinput.h @@ -272,4 +272,4 @@ FSerializer& Serialize(FSerializer& arc, const char* keyname, PlayerHorizon& w, void processMovement(InputPacket* currInput, InputPacket* inputBuffer, ControlInfo* const hidInput, double const scaleAdjust, int const drink_amt = 0, bool const allowstrafe = true, double const turnscale = 1); void sethorizon(fixedhoriz* horiz, float const horz, ESyncBits* actions, double const scaleAdjust = 1); void applylook(PlayerAngle* angle, float const avel, ESyncBits* actions, double const scaleAdjust = 1); -void calcviewpitch(vec2_t const pos, fixedhoriz* horizoff, binangle const ang, bool const aimmode, bool const canslopetilt, int const cursectnum, double const scaleAdjust, bool const climbing = false); +void calcviewpitch(vec2_t const pos, fixedhoriz* horizoff, binangle const ang, bool const aimmode, bool const canslopetilt, int const cursectnum, double const scaleAdjust = 1, bool const climbing = false); diff --git a/source/games/duke/src/inlines.h b/source/games/duke/src/inlines.h index 1cc44ebdf..abdf69b7c 100644 --- a/source/games/duke/src/inlines.h +++ b/source/games/duke/src/inlines.h @@ -193,7 +193,7 @@ inline double get16thOfHoriz(int const snum, bool const interpolate, double cons return (!interpolate ? ps[snum].horizon.sum() : ps[snum].horizon.interpolatedsum(smoothratio)).asq16() * (0.0625 / FRACUNIT); } -inline void doslopetilting(player_struct* p, double const scaleAdjust) +inline void doslopetilting(player_struct* p, double const scaleAdjust = 1) { bool const canslopetilt = p->on_ground && sector[p->cursectnum].lotag != ST_2_UNDERWATER && (sector[p->cursectnum].floorstat & 2); calcviewpitch(p->pos.vec2, &p->horizon.horizoff, p->angle.ang, p->aim_mode == 0, canslopetilt, p->cursectnum, scaleAdjust); diff --git a/source/games/duke/src/player_d.cpp b/source/games/duke/src/player_d.cpp index b93d62ac0..9ba455aae 100644 --- a/source/games/duke/src/player_d.cpp +++ b/source/games/duke/src/player_d.cpp @@ -2779,7 +2779,7 @@ void processinput_d(int snum) if (SyncInput()) { p->horizon.backup(); - doslopetilting(p, 1); + doslopetilting(p); } if (chz.type == kHitSprite) diff --git a/source/games/duke/src/player_r.cpp b/source/games/duke/src/player_r.cpp index 7afa1be35..2e55f3ab7 100644 --- a/source/games/duke/src/player_r.cpp +++ b/source/games/duke/src/player_r.cpp @@ -3461,7 +3461,7 @@ void processinput_r(int snum) if (SyncInput()) { p->horizon.backup(); - doslopetilting(p, 1); + doslopetilting(p); } if (chz.type == kHitSprite)