* Disable inverting on encore level select pictures at unanimous request of last night's netgame.

* Also, correct their alignment in y_inter.c.
This commit is contained in:
toaster 2018-08-14 15:32:17 +01:00
parent 2d92aefc29
commit 19b2c20bda
6 changed files with 19 additions and 7 deletions

View File

@ -6780,7 +6780,7 @@ static void M_DrawLevelSelectOnly(boolean leftfade, boolean rightfade)
if ((lumpnum = W_CheckNumForName(va("%sE", mapname))) != LUMPERROR)
mappingforencore = W_CachePatchNum(lumpnum, PU_CACHE);*/
V_DrawFixedPatch((x+w)<<FRACBITS, (y)<<FRACBITS, FRACUNIT/2, V_FLIP, PictureOfLevel, invertmap);
V_DrawFixedPatch((x+w)<<FRACBITS, (y)<<FRACBITS, FRACUNIT/2, V_FLIP, PictureOfLevel, 0);
{
static angle_t rubyfloattime = 0;

View File

@ -113,7 +113,9 @@ sprcache_t *spritecachedinfo;
lighttable_t *colormaps;
UINT8 *encoremap;
#ifdef HASINVERT
UINT8 invertmap[256];
#endif
// for debugging/info purposes
static size_t flatmemory, spritememory, texturememory;
@ -1020,7 +1022,9 @@ static void R_InitColormaps(void)
// Init Boom colormaps.
R_ClearColormaps();
//R_InitExtraColormaps();
#ifdef HASINVERT
R_MakeInvertmap(); // this isn't the BEST place to do it the first time, but whatever
#endif
}
void R_ReInitColormaps(UINT16 num, lumpnum_t newencoremap)
@ -1303,6 +1307,7 @@ void R_MakeColormaps(void)
colormapFixingArray[i][2]);
}
#ifdef HASINVERT
void R_MakeInvertmap(void)
{
size_t i;
@ -1310,6 +1315,7 @@ void R_MakeInvertmap(void)
for (i = 0; i < 256; i++)
invertmap[i] = NearestColor(256 - pLocalPalette[i].s.red, 256 - pLocalPalette[i].s.green, 256 - pLocalPalette[i].s.blue);
}
#endif
void R_CreateColormap2(char *p1, char *p2, char *p3)
{

View File

@ -95,7 +95,9 @@ INT32 R_ColormapNumForName(char *name);
INT32 R_CreateColormap(char *p1, char *p2, char *p3);
void R_CreateColormap2(char *p1, char *p2, char *p3);
void R_MakeColormaps(void);
#ifdef HASINVERT
void R_MakeInvertmap(void);
#endif
const char *R_ColormapNameForNum(INT32 num);
extern INT32 numtextures;

View File

@ -39,7 +39,9 @@ extern sprcache_t *spritecachedinfo;
extern lighttable_t *colormaps;
extern UINT8 *encoremap;
#ifdef HASINVERT
extern UINT8 invertmap[256];
#endif
// Boom colormaps.
// Had to put a limit on colormaps :(

View File

@ -248,7 +248,9 @@ void V_SetPaletteLump(const char *pal)
#endif
if (rendermode != render_none)
I_SetPalette(pLocalPalette);
#ifdef HASINVERT
R_MakeInvertmap();
#endif
}
static void CV_usegamma_OnChange(void)

View File

@ -1062,8 +1062,8 @@ void Y_VoteDrawer(void)
V_DrawSmallScaledPatch(BASEVIDWIDTH-100, y, V_SNAPTORIGHT, pic);
else
{
V_DrawFixedPatch((BASEVIDWIDTH-20)<<FRACBITS, (y)<<FRACBITS, FRACUNIT/2, V_FLIP, pic, invertmap);
V_DrawFixedPatch((BASEVIDWIDTH-60)<<FRACBITS, ((y+25)<<FRACBITS) - (rubyheight<<1), FRACUNIT, 0, rubyicon, NULL);
V_DrawFixedPatch((BASEVIDWIDTH-20)<<FRACBITS, (y)<<FRACBITS, FRACUNIT/2, V_FLIP|V_SNAPTORIGHT, pic, 0);
V_DrawFixedPatch((BASEVIDWIDTH-60)<<FRACBITS, ((y+25)<<FRACBITS) - (rubyheight<<1), FRACUNIT, V_SNAPTORIGHT, rubyicon, NULL);
}
V_DrawRightAlignedThinString(BASEVIDWIDTH-20, 40+y, V_SNAPTORIGHT, str);
@ -1085,8 +1085,8 @@ void Y_VoteDrawer(void)
V_DrawTinyScaledPatch(BASEVIDWIDTH-60, y, V_SNAPTORIGHT, pic);
else
{
V_DrawFixedPatch((BASEVIDWIDTH-20)<<FRACBITS, y<<FRACBITS, FRACUNIT/4, V_FLIP, pic, invertmap);
V_DrawFixedPatch((BASEVIDWIDTH-40)<<FRACBITS, (y<<FRACBITS) + (25<<(FRACBITS-1)) - rubyheight, FRACUNIT/2, 0, rubyicon, NULL);
V_DrawFixedPatch((BASEVIDWIDTH-20)<<FRACBITS, y<<FRACBITS, FRACUNIT/4, V_FLIP|V_SNAPTORIGHT, pic, 0);
V_DrawFixedPatch((BASEVIDWIDTH-40)<<FRACBITS, (y<<FRACBITS) + (25<<(FRACBITS-1)) - rubyheight, FRACUNIT/2, V_SNAPTORIGHT, rubyicon, NULL);
}
if (levelinfo[i].gts)
@ -1130,8 +1130,8 @@ void Y_VoteDrawer(void)
V_DrawTinyScaledPatch(x, y, V_SNAPTOLEFT, pic);
else
{
V_DrawFixedPatch((x+40)<<FRACBITS, (y)<<FRACBITS, FRACUNIT/4, V_SNAPTOLEFT|V_FLIP, pic, invertmap);
V_DrawFixedPatch((x+20)<<FRACBITS, (y<<FRACBITS) + (25<<(FRACBITS-1)) - rubyheight, FRACUNIT/2, 0, rubyicon, NULL);
V_DrawFixedPatch((x+40)<<FRACBITS, (y)<<FRACBITS, FRACUNIT/4, V_SNAPTOLEFT|V_FLIP, pic, 0);
V_DrawFixedPatch((x+20)<<FRACBITS, (y<<FRACBITS) + (25<<(FRACBITS-1)) - rubyheight, FRACUNIT/2, V_SNAPTORIGHT, rubyicon, NULL);
}
if (levelinfo[votes[i]].gts)