From 537a0684057830ae9c96c921c2a0237f14c951be Mon Sep 17 00:00:00 2001 From: Christopher Schwarz Date: Sun, 5 Dec 2010 04:05:21 +0000 Subject: * (bug 4268) Disable vote bind instructions when tutorial mode is off * (bug 4811) Fix colour bleed in vote reasons (Brian "Teapot" Shannon) * Decolour vote caller for consistency with the other vote elements --- src/cgame/cg_draw.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) (limited to 'src/cgame') diff --git a/src/cgame/cg_draw.c b/src/cgame/cg_draw.c index 848b20d3..24bc2d94 100644 --- a/src/cgame/cg_draw.c +++ b/src/cgame/cg_draw.c @@ -3057,7 +3057,7 @@ static void CG_DrawVote( team_t team ) char *s; int sec; vec4_t white = { 1.0f, 1.0f, 1.0f, 1.0f }; - char yeskey[ 32 ], nokey[ 32 ]; + char yeskey[ 32 ] = "", nokey[ 32 ] = ""; if( !cgs.voteTime[ team ] ) return; @@ -3074,13 +3074,16 @@ static void CG_DrawVote( team_t team ) if( sec < 0 ) sec = 0; - Q_strncpyz( yeskey, - CG_KeyBinding( va( "%svote yes", team == TEAM_NONE ? "" : "team" ) ), - sizeof( yeskey ) ); - Q_strncpyz( nokey, - CG_KeyBinding( va( "%svote no", team == TEAM_NONE ? "" : "team" ) ), - sizeof( nokey ) ); - s = va( "%sVOTE(%i): \"%s\" called by \"%s" S_COLOR_WHITE "\" [%s]Yes:%i [%s]No:%i", + if( cg_tutorial.integer ) + { + Com_sprintf( yeskey, sizeof( yeskey ), "[%s]", + CG_KeyBinding( va( "%svote yes", team == TEAM_NONE ? "" : "team" ) ) ); + Com_sprintf( nokey, sizeof( nokey ), "[%s]", + CG_KeyBinding( va( "%svote no", team == TEAM_NONE ? "" : "team" ) ) ); + } + + s = va( "%sVOTE(%i): \"%s" S_COLOR_WHITE "\" called by \"%s" + S_COLOR_WHITE "\" %sYes:%i %sNo:%i", team == TEAM_NONE ? "" : "TEAM", sec, cgs.voteString[ team ], cgs.voteCaller[ team ], yeskey, cgs.voteYes[ team ], nokey, cgs.voteNo[ team ] ); -- cgit