diff --git a/src/hardware/hw_draw.c b/src/hardware/hw_draw.c index f1e53bb28..d9e688c0a 100644 --- a/src/hardware/hw_draw.c +++ b/src/hardware/hw_draw.c @@ -1080,7 +1080,7 @@ void HWR_drawAMline(const fline_t *fl, INT32 color) // -------------------+ // HWR_DrawConsoleFill : draw flat coloured transparent rectangle because that's cool, and hw sucks less than sw for that. // -------------------+ -void HWR_DrawConsoleFill(INT32 x, INT32 y, INT32 w, INT32 h, UINT32 color) +void HWR_DrawConsoleFill(INT32 x, INT32 y, INT32 w, INT32 h, INT32 color, UINT32 actualcolor) { FOutVector v[4]; FSurfaceInfo Surf; @@ -1239,7 +1239,7 @@ void HWR_DrawConsoleFill(INT32 x, INT32 y, INT32 w, INT32 h, UINT32 color) v[0].tow = v[1].tow = 0.0f; v[2].tow = v[3].tow = 1.0f; - Surf.FlatColor.rgba = UINT2RGBA(color); + Surf.FlatColor.rgba = UINT2RGBA(actualcolor); Surf.FlatColor.s.alpha = 0x80; HWD.pfnDrawPolygon(&Surf, v, 4, PF_NoTexture|PF_Modulated|PF_Translucent|PF_NoDepthTest); diff --git a/src/hardware/hw_main.h b/src/hardware/hw_main.h index d706aae86..f8524990f 100644 --- a/src/hardware/hw_main.h +++ b/src/hardware/hw_main.h @@ -50,7 +50,7 @@ void HWR_CreateStaticLightmaps(INT32 bspnum); void HWR_PrepLevelCache(size_t pnumtextures); void HWR_DrawFill(INT32 x, INT32 y, INT32 w, INT32 h, INT32 color); void HWR_DrawFadeFill(INT32 x, INT32 y, INT32 w, INT32 h, INT32 color, UINT16 actualcolor, UINT8 strength); -void HWR_DrawConsoleFill(INT32 x, INT32 y, INT32 w, INT32 h, UINT32 color); // Lat: separate flags from color since color needs to be an uint to work right. +void HWR_DrawConsoleFill(INT32 x, INT32 y, INT32 w, INT32 h, INT32 color, UINT32 actualcolor); // Lat: separate flags from color since color needs to be an uint to work right. void HWR_DrawPic(INT32 x,INT32 y,lumpnum_t lumpnum); UINT8 *HWR_GetScreenshot(void); diff --git a/src/hardware/hw_md2.c b/src/hardware/hw_md2.c index c2faa8b86..86097822e 100644 --- a/src/hardware/hw_md2.c +++ b/src/hardware/hw_md2.c @@ -1214,7 +1214,6 @@ static UINT8 P_GetModelSprite2(md2_t *md2, skin_t *skin, UINT8 spr2, player_t *p switch(spr2) { - // Normal special cases. case SPR2_JUMP: spr2 = ((player @@ -1228,7 +1227,6 @@ static UINT8 P_GetModelSprite2(md2_t *md2, skin_t *skin, UINT8 spr2, player_t *p : skin->ability) == CA_SWIM) ? SPR2_SWIM : SPR2_FLY; break; - // Use the handy list, that's what it's there for! default: spr2 = spr2defaults[spr2]; diff --git a/src/p_mobj.c b/src/p_mobj.c index 7ff8aa9f2..e2daf26e3 100644 --- a/src/p_mobj.c +++ b/src/p_mobj.c @@ -9717,7 +9717,7 @@ mobj_t *P_SpawnMobj(fixed_t x, fixed_t y, fixed_t z, mobjtype_t type) case MT_EGGROBO1: mobj->movecount = P_RandomKey(13); mobj->color = SKINCOLOR_RUBY + P_RandomKey(MAXSKINCOLORS - SKINCOLOR_RUBY); - // fall through + break; case MT_HIVEELEMENTAL: mobj->extravalue1 = 5; break; @@ -11117,7 +11117,7 @@ You should think about modifying the deathmatch starts to take full advantage of mobj->color = SKINCOLOR_GOLD; mobj->colorized = true; } - // fall through + break; case MT_EGGMOBILE3: mobj->cusval = mthing->extrainfo; break; diff --git a/src/r_things.c b/src/r_things.c index fdf0e230d..645d10015 100644 --- a/src/r_things.c +++ b/src/r_things.c @@ -2527,7 +2527,6 @@ UINT8 P_GetSkinSprite2(skin_t *skin, UINT8 spr2, player_t *player) switch(spr2) { - // Normal special cases. case SPR2_JUMP: spr2 = ((player @@ -2540,8 +2539,7 @@ UINT8 P_GetSkinSprite2(skin_t *skin, UINT8 spr2, player_t *player) ? player->charability : skin->ability) == CA_SWIM) ? SPR2_SWIM : SPR2_FLY; - // fall through - + break; // Use the handy list, that's what it's there for! default: spr2 = spr2defaults[spr2]; diff --git a/src/sdl/mixer_sound.c b/src/sdl/mixer_sound.c index ff2b029a5..64b7cc722 100644 --- a/src/sdl/mixer_sound.c +++ b/src/sdl/mixer_sound.c @@ -158,14 +158,14 @@ static void MidiSoundfontPath_Onchange(void) if (stricmp(Mix_GetSoundFonts(), cv_midisoundfontpath.string)) { - char *token; + char *miditoken; char *source = strdup(cv_midisoundfontpath.string); boolean proceed = true; // check if file exists; menu calls this method at every keystroke - while ((token = strtok_r(source, ";", &source))) + while ((miditoken = strtok_r(source, ";", &source))) { - SDL_RWops *rw = SDL_RWFromFile(token, "r"); + SDL_RWops *rw = SDL_RWFromFile(miditoken, "r"); if (rw != NULL) SDL_RWclose(rw); else diff --git a/src/v_video.c b/src/v_video.c index cc9040f04..2ec06a787 100644 --- a/src/v_video.c +++ b/src/v_video.c @@ -1374,7 +1374,7 @@ void V_DrawFillConsoleMap(INT32 x, INT32 y, INT32 w, INT32 h, INT32 c) if (rendermode != render_soft && rendermode != render_none) { UINT32 hwcolor = V_GetHWConsBackColor(); - HWR_DrawConsoleFill(x, y, w, h, hwcolor); // we still use the regular color stuff but only for flags. actual draw color is "hwcolor" for this. + HWR_DrawConsoleFill(x, y, w, h, c, hwcolor); // we still use the regular color stuff but only for flags. actual draw color is "hwcolor" for this. return; } #endif