X-Git-Url: https://git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fserver%2Fclient.qc;h=0c12e40f0198b0d8063198acdaf30243e0984c2a;hb=dbe33129e12ed79bcd09e4063157d5abfe1d9ea5;hp=24ed8ffbbdd95646303ac900bf61d6b9abfc8640;hpb=f7e94367c693a88e837313f969d1500cb36f8938;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/client.qc b/qcsrc/server/client.qc index 24ed8ffbb..0c12e40f0 100644 --- a/qcsrc/server/client.qc +++ b/qcsrc/server/client.qc @@ -113,20 +113,18 @@ bool ClientData_Send(entity this, entity to, int sf) if (IS_SPEC(e)) e = e.enemy; sf = 0; - if (CS(e).race_completed) sf |= 1; // forced scoreboard - if (CS(to).spectatee_status) sf |= 2; // spectator ent number follows - if (CS(e).zoomstate) sf |= 4; // zoomed - if (autocvar_sv_showspectators) sf |= 16; // show spectators + if (CS(e).race_completed) sf |= BIT(0); // forced scoreboard + if (CS(to).spectatee_status) sf |= BIT(1); // spectator ent number follows + if (CS(e).zoomstate) sf |= BIT(2); // zoomed + if (autocvar_sv_showspectators) sf |= BIT(4); // show spectators WriteHeader(MSG_ENTITY, ENT_CLIENT_CLIENTDATA); WriteByte(MSG_ENTITY, sf); - if (sf & 2) - { + if (sf & BIT(1)) WriteByte(MSG_ENTITY, CS(to).spectatee_status); - } - if(sf & 16) + if(sf & BIT(4)) { float specs = CountSpectators(e, to); WriteByte(MSG_ENTITY, specs);