diff options
author | Theriaca <reichmeister@protonmail.com> | 2018-11-03 18:46:09 +0100 |
---|---|---|
committer | Theriaca <reichmeister@protonmail.com> | 2018-11-03 18:46:09 +0100 |
commit | 35a81dd50a340b1175c715bb754ce2b2e454425e (patch) | |
tree | 6e7031ac4edb1743111a2ff4676fb0335a022128 /src/game | |
parent | 14e6315f417cec61b12c033464972da8c52b8cde (diff) |
show the voters what they voted
Diffstat (limited to 'src/game')
-rw-r--r-- | src/game/g_cmds.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c index d241e19..fb59950 100644 --- a/src/game/g_cmds.c +++ b/src/game/g_cmds.c @@ -2500,18 +2500,18 @@ void Cmd_Vote_f( gentity_t *ent ) return; } - trap_SendServerCommand( ent-g_entities, "print \"Vote cast\n\"" ); - trap_Argv( 1, msg, sizeof( msg ) ); if( msg[ 0 ] == 'y' || msg[ 1 ] == 'Y' || msg[ 1 ] == '1' ) { + trap_SendServerCommand( ent-g_entities, "print \"Vote cast: ^2Yes\n\"" ); level.voteYes++; level.votedHow[ ent - g_entities ] = 1; trap_SetConfigstring( CS_VOTE_YES, va( "%i", level.voteYes ) ); } else { + trap_SendServerCommand( ent-g_entities, "print \"Vote cast: ^1No\n\"" ); level.voteNo++; level.votedHow[ ent - g_entities ] = -1; trap_SetConfigstring( CS_VOTE_NO, va( "%i", level.voteNo ) ); @@ -2974,18 +2974,18 @@ void Cmd_TeamVote_f( gentity_t *ent ) return; } - trap_SendServerCommand( ent-g_entities, "print \"Team vote cast\n\"" ); - trap_Argv( 1, msg, sizeof( msg ) ); if( msg[ 0 ] == 'y' || msg[ 1 ] == 'Y' || msg[ 1 ] == '1' ) { + trap_SendServerCommand( ent-g_entities, "print \"Team vote cast: ^2Yes\n\"" ); level.teamVotedHow[ cs_offset ][ ent - g_entities ] = 1; level.teamVoteYes[ cs_offset ]++; trap_SetConfigstring( CS_TEAMVOTE_YES + cs_offset, va( "%i", level.teamVoteYes[ cs_offset ] ) ); } else { + trap_SendServerCommand( ent-g_entities, "print \"Team vote cast: ^1No\n\"" ); level.teamVotedHow[ cs_offset ][ ent - g_entities ] = -1; level.teamVoteNo[ cs_offset ]++; trap_SetConfigstring( CS_TEAMVOTE_NO + cs_offset, va( "%i", level.teamVoteNo[ cs_offset ] ) ); |