entity e;
WriteByte(MSG_ENTITY, ENT_CLIENT_NAGGER);
+ // bits:
+ // 1 = ready
+ // 2 = player needs to ready up
+ // 4 = vote
+ // 8 = player needs to vote
+ // 16 = warmup
+ // sendflags:
+ // 64 = vote counts
+ // 128 = vote string
+
nags = 0;
if(readycount)
{
if(inWarmupStage)
nags |= 16;
+ if(sendflags & 64)
+ nags |= 64;
+
if(sendflags & 128)
nags |= 128;
if(!(nags & 4)) // no vote called? send no string
- nags &~= 128;
+ nags &~= (64 | 128);
WriteByte(MSG_ENTITY, nags);
- if(nags & 128)
+ if(nags & 64)
{
- WriteString(MSG_ENTITY, votecalledvote_display);
+ WriteByte(MSG_ENTITY, vote_yescount);
+ WriteByte(MSG_ENTITY, vote_nocount);
+ WriteByte(MSG_ENTITY, vote_needed_absolute);
+ WriteChar(MSG_ENTITY, to.vote_vote);
}
+ if(nags & 128)
+ WriteString(MSG_ENTITY, votecalledvote_display);
+
if(nags & 1)
{
for(i = 1; i <= maxclients; i += 8)
void Nagger_VoteCountChanged()
{
if(nagger)
- nagger.SendFlags |= 1;
+ nagger.SendFlags |= 64;
}
void Nagger_ReadyCounted()
{
default:
clientcommand(self, command); //print("Invalid command. For a list of supported commands, try cmd help.\n");
}
-}
\ No newline at end of file
+}