Skip to content

Commit

Permalink
Added (all games): Implemented a new scoreboard for all types of mult…
Browse files Browse the repository at this point in the history
…iplayer game. All of the old frag displays have been removed. The scoreboard is visible by holding the '\' backslash key (by default) while in a multiplayer game. Note that this is an initial implementation and there are a few things that remain to be fixed (and cleaned up).
  • Loading branch information
danij committed Aug 26, 2008
1 parent b9170b8 commit 74bde8c
Show file tree
Hide file tree
Showing 10 changed files with 594 additions and 181 deletions.
4 changes: 3 additions & 1 deletion doomsday/plugins/common/include/g_controls.h
Expand Up @@ -93,7 +93,8 @@ enum {
CTL_MAP_ROTATE,
CTL_MAP_MARK_ADD,
CTL_MAP_MARK_CLEAR_ALL,
CTL_HUD_SHOW
CTL_HUD_SHOW,
CTL_SCORE_SHOW
};

// This structure replaced ticcmd as the place where players store the intentions
Expand All @@ -118,6 +119,7 @@ typedef struct playerbrain_s {
uint mapMarkAdd : 1;
uint mapMarkClearAll : 1;
uint hudShow : 1;
uint scoreShow : 1;
} playerbrain_t;

void G_ControlRegister(void);
Expand Down
9 changes: 5 additions & 4 deletions doomsday/plugins/common/include/hu_stuff.h
Expand Up @@ -76,8 +76,6 @@ extern boolean messageNoEcho;
extern int typeInTime;
extern boolean chatOn;

extern boolean huShowAllFrags;

#if __JDOOM__
// Plutonia and TNT map names.
extern char *mapNamesPlut[32], *mapNamesTNT[32];
Expand Down Expand Up @@ -123,9 +121,9 @@ void Draw_EndZoom(void);

void HU_Register(void);

void HU_Start(void);
void HU_Start(int player);
void HU_UnloadData(void);
void HU_Drawer(void);
void HU_Drawer(int player);
char HU_dequeueChatChar(void);
void HU_Erase(void);

Expand All @@ -134,4 +132,7 @@ void HU_DrawMapCounters(void);
void Hu_DrawFogEffect(int effectID, DGLuint tex, float texOffset[2],
float texAngle, float alpha, float arg1);

void HU_ScoreBoardUnHide(int player);
void HU_DrawScoreBoard(int player);

#endif
2 changes: 2 additions & 0 deletions doomsday/plugins/common/src/g_controls.c
Expand Up @@ -251,6 +251,7 @@ void G_ControlRegister(void)
P_NewPlayerControl(CTL_MAP_MARK_CLEAR_ALL, CTLT_IMPULSE, "clearmarks", "map");

P_NewPlayerControl(CTL_HUD_SHOW, CTLT_IMPULSE, "showhud", "game");
P_NewPlayerControl(CTL_SCORE_SHOW, CTLT_IMPULSE, "showscore", "game");
}

DEFCC( CCmdDefaultGameBinds )
Expand Down Expand Up @@ -387,6 +388,7 @@ DEFCC( CCmdDefaultGameBinds )
"bindevent key-p pause",

"bindevent key-h {impulse showhud}",
"bindevent key-backslash-repeat {impulse showscore}",
"bindevent key-minus {viewsize -}",
"bindevent key-equals {viewsize +}",
"bindevent key-return msgrefresh",
Expand Down

0 comments on commit 74bde8c

Please sign in to comment.