From c6c239c61b109dffe4fbf1e5a460421000634d9b Mon Sep 17 00:00:00 2001 From: div0 Date: Sun, 28 Sep 2008 09:43:20 +0000 Subject: [PATCH] fix vote nagger git-svn-id: svn://svn.icculus.org/nexuiz/trunk@4538 f962a42d-fe04-0410-a3ab-8c8b0445ebaa --- data/qcsrc/client/sbar.qc | 22 +++++++++++----------- data/qcsrc/server/clientcommands.qc | 11 +++++++++-- 2 files changed, 20 insertions(+), 13 deletions(-) diff --git a/data/qcsrc/client/sbar.qc b/data/qcsrc/client/sbar.qc index 7f83d3ec8..e71036ab9 100644 --- a/data/qcsrc/client/sbar.qc +++ b/data/qcsrc/client/sbar.qc @@ -1376,10 +1376,10 @@ void Sbar_Draw (void) else if(sk.(scores[ps_primary]) > 0) s = "^1You have no more lives left"; else - s = strcat("^1Press ^7", getcommandkey("jump", "+jump"), "^1 to join"); + s = strcat("^1Press ^3", getcommandkey("jump", "+jump"), "^1 to join"); } else - s = strcat("^1Press ^7", getcommandkey("jump", "+jump"), "^1 to join"); + s = strcat("^1Press ^3", getcommandkey("jump", "+jump"), "^1 to join"); o = Sbar_DrawNoteLine(o, s); } @@ -1388,38 +1388,38 @@ void Sbar_Draw (void) if(ready_waiting_for_me) { if(warmup_stage) - s = strcat("^1Press ^3", getcommandkey("ready", "ready"), "^1 to end warmup"); + s = strcat("^2Press ^3", getcommandkey("ready", "ready"), "^2 to end warmup"); else - s = strcat("^1Press ^3", getcommandkey("ready", "ready"), "^1 once you are ready"); + s = strcat("^2Press ^3", getcommandkey("ready", "ready"), "^2 once you are ready"); } else { if(warmup_stage) - s = strcat("^1Waiting for others to ready up to end warmup..."); + s = strcat("^2Waiting for others to ready up to end warmup..."); else - s = strcat("^1Waiting for others to ready up..."); + s = strcat("^2Waiting for others to ready up..."); } o = Sbar_DrawNoteLine(o, s); } if(vote_waiting) { - s = strcat("^1A vote has been called for ", vote_called_vote); + s = strcat("^2A vote has been called for ^1", vote_called_vote); o = Sbar_DrawNoteLine(o, s); if(vote_waiting_for_me) { - s = strcat("^1Press ^3", getcommandkey("vote yes", "vyes"), "^1 to accept"); + s = strcat("^2Press ^3", getcommandkey("vote yes", "vyes"), "^2 to accept"); o = Sbar_DrawNoteLine(o, s); - s = strcat("^1Press ^3", getcommandkey("vote no", "vno"), "^1 to reject"); + s = strcat("^2Press ^3", getcommandkey("vote no", "vno"), "^2 to reject"); o = Sbar_DrawNoteLine(o, s); - s = strcat("^1Press ^3", getcommandkey("vote abstain", "vabstain"), "^1 to abstain"); + s = strcat("^2Press ^3", getcommandkey("vote abstain", "vabstain"), "^2 to abstain"); o = Sbar_DrawNoteLine(o, s); } else { - s = strcat("^1Waiting for others to vote..."); + s = strcat("^2Waiting for others to vote..."); o = Sbar_DrawNoteLine(o, s); } } diff --git a/data/qcsrc/server/clientcommands.qc b/data/qcsrc/server/clientcommands.qc index 7d17241a4..9f767a702 100644 --- a/data/qcsrc/server/clientcommands.qc +++ b/data/qcsrc/server/clientcommands.qc @@ -1,6 +1,6 @@ entity nagger; float readycount; -void Nagger_SendEntity(entity to, float sendflags) +float Nagger_SendEntity(entity to, float sendflags) { float nags; WriteByte(MSG_ENTITY, ENT_CLIENT_NAGGER); @@ -22,10 +22,15 @@ void Nagger_SendEntity(entity to, float sendflags) if(sendflags & 128) { WriteByte(MSG_ENTITY, nags | 128); - WriteString(MSG_ENTITY, votecalledvote); + if(votecalled) + WriteString(MSG_ENTITY, votecalledvote_display); + else + WriteString(MSG_ENTITY, ""); } else WriteByte(MSG_ENTITY, nags); + + return TRUE; } void Nagger_Init() { @@ -36,11 +41,13 @@ void Nagger_Init() } void Nagger_VoteChanged() { + print("VoteChanged\n"); if(nagger) nagger.SendFlags = 128; } void Nagger_ReadyCounted() { + print("ReadyCounted\n"); if(nagger) nagger.SendFlags = 1; } -- 2.39.2