From eec54356c3b50b28ec89f0fa7015f6d6b3896904 Mon Sep 17 00:00:00 2001 From: James R Date: Mon, 26 Oct 2020 18:57:32 -0700 Subject: [PATCH] Fix splitscreen fov being fucked on first R_ExecuteSetViewSize --- src/r_main.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/src/r_main.c b/src/r_main.c index c64907450..8e05b8d27 100644 --- a/src/r_main.c +++ b/src/r_main.c @@ -601,6 +601,12 @@ static inline void R_InitLightTables(void) //#define WOUGHMP_WOUGHMP // I got a fish-eye lens - I'll make a rap video with a couple of friends // it's kinda laggy sometimes +#ifdef WOUGHMP_WOUGHMP +#define AHHHH_IM_SO_MAAAAD { 0U, 0, FRACUNIT, NULL, 0, 0, {0}, {0}, false } +#else +#define AHHHH_IM_SO_MAAAAD { 0U, FRACUNIT, NULL, 0, 0, {0}, {0}, false } +#endif + static struct viewmorph { angle_t rollangle; // pre-shifted by fineshift #ifdef WOUGHMP_WOUGHMP @@ -615,7 +621,14 @@ static struct viewmorph { INT16 ceilingclip[MAXVIDWIDTH], floorclip[MAXVIDWIDTH]; boolean use; -} viewmorph[MAXSPLITSCREENPLAYERS] = {0}; +} viewmorph[MAXSPLITSCREENPLAYERS] = { + AHHHH_IM_SO_MAAAAD, + AHHHH_IM_SO_MAAAAD, + AHHHH_IM_SO_MAAAAD, + AHHHH_IM_SO_MAAAAD, +}; + +#undef AHHHH_IM_SO_MAAAAD void R_CheckViewMorph(int s) { @@ -643,11 +656,6 @@ void R_CheckViewMorph(int s) fixed_t fisheye = cv_cam2_turnmultiplier.value; // temporary test value #endif - if (v->zoomneeded == 0) - { - v->zoomneeded = FRACUNIT; - } - rollangle >>= ANGLETOFINESHIFT; rollangle = ((rollangle+2) & ~3) & FINEMASK; // Limit the distinct number of angles to reduce recalcs from angles changing a lot.