Skip to content

Commit

Permalink
Implement flashing HOM indicator
Browse files Browse the repository at this point in the history
Flashes between red and black, except when player has no clipping mode
cheat enabled.
  • Loading branch information
bradharding committed May 5, 2014
1 parent 1c5b988 commit fc33ae8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/r_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ int translucency = true;

extern int automapactive;
extern int viewheight2;
extern int gametic;
extern boolean canmodify;

void (*colfunc)(void);
Expand Down Expand Up @@ -520,8 +521,8 @@ void R_RenderPlayerView(player_t *player)
R_ClearPlanes();
R_ClearSprites();

if (player->cheats & CF_NOCLIP)
V_FillRect(0, viewwindowx, viewwindowy, viewwidth, viewheight, 0);
V_FillRect(0, viewwindowx, viewwindowy, viewwidth, viewheight,
(gametic % 20) >= 9 || (player->cheats & CF_NOCLIP) ? 0 : 176);

// The head node is the last node output.
R_RenderBSPNode(numnodes - 1);
Expand Down

0 comments on commit fc33ae8

Please sign in to comment.