From 04eddacd65fd3da680e3d896368cb766b377e6e2 Mon Sep 17 00:00:00 2001 From: Magnus Auvinen Date: Sun, 31 Aug 2008 21:50:14 +0000 Subject: setting of correct game type in game controller. fixed gametype filter in browser. various cleanups --- src/game/client/components/scoreboard.cpp | 31 +++++++++++++++++++------------ 1 file changed, 19 insertions(+), 12 deletions(-) (limited to 'src/game/client/components/scoreboard.cpp') diff --git a/src/game/client/components/scoreboard.cpp b/src/game/client/components/scoreboard.cpp index bd8c7ea9..2388c4c3 100644 --- a/src/game/client/components/scoreboard.cpp +++ b/src/game/client/components/scoreboard.cpp @@ -225,23 +225,30 @@ void SCOREBOARD::render_scoreboard(float x, float y, float w, int team, const ch void SCOREBOARD::on_render() { - if(!active) - return; - - // if the score board is active, then we should clear the motd message aswell - gameclient.motd->clear(); - - // TODO: repair me - /* bool do_scoreboard = false; - // if we are dead - if(!spectate && (!gameclient.snap.local_character || gameclient.snap.local_character->health < 0)) + // if we activly wanna look on the scoreboard + if(active) do_scoreboard = true; - + + if(gameclient.snap.local_info && gameclient.snap.local_info->team != -1) + { + // we are not a spectator, check if we are ead + if(!gameclient.snap.local_character || gameclient.snap.local_character->health < 0) + do_scoreboard = true; + } + // if we the game is over if(gameclient.snap.gameobj && gameclient.snap.gameobj->game_over) - do_scoreboard = true;*/ + do_scoreboard = true; + + if(!do_scoreboard) + return; + + // if the score board is active, then we should clear the motd message aswell + if(active) + gameclient.motd->clear(); + float width = 400*3.0f*gfx_screenaspect(); float height = 400*3.0f; -- cgit 1.4.1