Add tc_colormaps cvar

This commit is contained in:
Lactozilla 2023-06-25 04:28:00 -03:00
parent 75f8a18a6c
commit 69bc200c3c
2 changed files with 10 additions and 2 deletions

View file

@ -180,6 +180,10 @@ consvar_t cv_homremoval = CVAR_INIT ("homremoval", "No", CV_SAVE, homremoval_con
consvar_t cv_maxportals = CVAR_INIT ("maxportals", "2", CV_SAVE, maxportals_cons_t, NULL);
#ifdef TRUECOLOR
consvar_t cv_tccolormaps = CVAR_INIT ("tc_colormaps", "Off", CV_SAVE, CV_OnOff, NULL);
#endif
consvar_t cv_renderstats = CVAR_INIT ("renderstats", "Off", 0, CV_OnOff, NULL);
void SplitScreen_OnChange(void)
@ -1474,8 +1478,8 @@ void R_RenderPlayerView(player_t *player)
}
#ifdef TRUECOLOR
tc_colormaps = false;
tc_spritecolormaps = truecolor;
tc_colormaps = truecolor && cv_tccolormaps.value;
tc_spritecolormaps = tc_colormaps;
#endif
R_SetupFrame(player);
@ -1659,6 +1663,8 @@ void R_RegisterEngineStuff(void)
CV_RegisterVar(&cv_maxportals);
CV_RegisterVar(&cv_tccolormaps);
CV_RegisterVar(&cv_movebob);
// Frame interpolation/uncapped

View file

@ -96,6 +96,8 @@ extern mobj_t *r_viewmobj;
extern consvar_t cv_allowmlook;
extern consvar_t cv_maxportals;
extern consvar_t cv_tccolormaps;
extern angle_t clipangle;
extern angle_t doubleclipangle;