From 0a48454a554f8aa221a54b694b32b3004b9f6fd7 Mon Sep 17 00:00:00 2001 From: Magnus Auvinen Date: Sun, 31 Aug 2008 14:37:35 +0000 Subject: removed the GAMETYPE_ enum --- src/game/client/components/hud.cpp | 3 +-- src/game/client/components/killmessages.cpp | 4 ++-- src/game/client/components/menus_settings.cpp | 6 +----- 3 files changed, 4 insertions(+), 9 deletions(-) (limited to 'src/game/client') diff --git a/src/game/client/components/hud.cpp b/src/game/client/components/hud.cpp index 5349401b..762ed1fb 100644 --- a/src/game/client/components/hud.cpp +++ b/src/game/client/components/hud.cpp @@ -31,7 +31,6 @@ void HUD::render_goals() // render_scorehud // render_warmuptimer - int gametype = gameclient.snap.gameobj->gametype; int gameflags = gameclient.snap.gameobj->flags; float whole = 300*gfx_screenaspect(); @@ -84,7 +83,7 @@ void HUD::render_goals() str_format(buf, sizeof(buf), "%d", t?gameclient.snap.gameobj->teamscore_blue:gameclient.snap.gameobj->teamscore_red); float w = gfx_text_width(0, 14, buf, -1); - if(gametype == GAMETYPE_CTF) + if(gameflags&GAMEFLAG_FLAGS) { gfx_text(0, whole-20-w/2+5, 300-40-15+t*20, 14, buf, -1); if(gameclient.snap.flags[t]) diff --git a/src/game/client/components/killmessages.cpp b/src/game/client/components/killmessages.cpp index 106433f5..410f2c3d 100644 --- a/src/game/client/components/killmessages.cpp +++ b/src/game/client/components/killmessages.cpp @@ -62,7 +62,7 @@ void KILLMESSAGES::on_render() // render victim tee x -= 24.0f; - if(gameclient.snap.gameobj && gameclient.snap.gameobj->gametype == GAMETYPE_CTF) + if(gameclient.snap.gameobj && gameclient.snap.gameobj->flags&GAMEFLAG_FLAGS) { if(killmsgs[r].mode_special&1) { @@ -96,7 +96,7 @@ void KILLMESSAGES::on_render() if(killmsgs[r].victim != killmsgs[r].killer) { - if(gameclient.snap.gameobj && gameclient.snap.gameobj->gametype == GAMETYPE_CTF) + if(gameclient.snap.gameobj && gameclient.snap.gameobj->flags&GAMEFLAG_FLAGS) { if(killmsgs[r].mode_special&2) { diff --git a/src/game/client/components/menus_settings.cpp b/src/game/client/components/menus_settings.cpp index 95a097c2..e43793a4 100644 --- a/src/game/client/components/menus_settings.cpp +++ b/src/game/client/components/menus_settings.cpp @@ -4,11 +4,7 @@ #include // strcmp, strlen, strncpy #include // atoi -extern "C" { - #include - #include - #include -} +#include #include #include -- cgit 1.4.1