From ddd357d27c78ffa3102505b46635e676eb2e85ac Mon Sep 17 00:00:00 2001 From: Marco Z Date: Tue, 20 Nov 2018 21:54:20 -0500 Subject: [PATCH] VC build fixes --- src/hardware/hw_main.c | 2 +- src/m_cheat.c | 2 +- src/p_saveg.c | 2 +- src/st_stuff.c | 9 +++++---- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/hardware/hw_main.c b/src/hardware/hw_main.c index 2e9e5726a..cb37c39ae 100644 --- a/src/hardware/hw_main.c +++ b/src/hardware/hw_main.c @@ -5731,7 +5731,7 @@ static void HWR_DrawSkyBackground(player_t *player) dimensionmultiply = ((float)textures[texturetranslation[skytexture]]->width/256.0f); - v[0].sow = v[3].sow = ((float) (-angle) / ((ANGLE_90-1)*dimensionmultiply)); // left + v[0].sow = v[3].sow = ((float) (-(float)angle) / ((ANGLE_90-1)*dimensionmultiply)); // left v[2].sow = v[1].sow = v[0].sow + (1.0f/dimensionmultiply); // right (or left + 1.0f) // use +angle and -1.0f above instead if you wanted old backwards behavior diff --git a/src/m_cheat.c b/src/m_cheat.c index 473209350..79a52fe9f 100644 --- a/src/m_cheat.c +++ b/src/m_cheat.c @@ -571,7 +571,7 @@ void Command_Teleport_f(void) } else // scan the thinkers to find starposts... { - mobj_t *mo2; + mobj_t *mo2 = NULL; thinker_t *th; INT32 starpostmax = 0; diff --git a/src/p_saveg.c b/src/p_saveg.c index 6a07e513f..f0a8757c1 100644 --- a/src/p_saveg.c +++ b/src/p_saveg.c @@ -486,7 +486,7 @@ static UINT32 num_ffloors = 0; // for loading // But also check for equality and return the matching index static UINT32 CheckAddNetColormapToList(extracolormap_t *extra_colormap) { - extracolormap_t *exc, *exc_prev; + extracolormap_t *exc, *exc_prev = NULL; UINT32 i = 0; if (!net_colormaps) diff --git a/src/st_stuff.c b/src/st_stuff.c index 26d9678a3..4f628b078 100644 --- a/src/st_stuff.c +++ b/src/st_stuff.c @@ -1509,7 +1509,7 @@ static void ST_drawNiGHTSLink(void) else colornum = linkColor[mag][sel]; - aflag |= ((stplyr->linktimer < nightslinktics/3) + aflag |= ((stplyr->linktimer < (UINT32)nightslinktics/3) ? (9 - 9*stplyr->linktimer/(nightslinktics/3)) << V_ALPHASHIFT : 0); @@ -1613,11 +1613,12 @@ static void ST_drawNiGHTSHUD(void) #endif ST_DrawTopLeftOverlayPatch(16, 8, nbracket); if (G_IsSpecialStage(gamemap)) - ST_DrawTopLeftOverlayPatch(24, 16, ( #ifdef MANIASPHERES - (stplyr->bonustime && (leveltime & 4)) ? nssbon : + ST_DrawTopLeftOverlayPatch(24, 16, ( + (stplyr->bonustime && (leveltime & 4)) ? nssbon : nsshud)); +#else + ST_DrawTopLeftOverlayPatch(24, 16, (nsshud)); #endif - nsshud)); else ST_DrawTopLeftOverlayPatch(24, 16, *(((stplyr->bonustime) ? nbon : nhud)+((leveltime/2)%12)));