X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fclient%2FMain.qc;h=0c7643d0efa2019452f9eb1468cd572adf36fc9c;hp=95a01ab0e767501ac9b257ff2b266536dbe893cf;hb=f2a79cba0897fb6f6cb7ebeecb596b5547af3ddd;hpb=ead998eb93f3b5df0d46e09455e7aa8fef44540d diff --git a/qcsrc/client/Main.qc b/qcsrc/client/Main.qc index 95a01ab0e..0c7643d0e 100644 --- a/qcsrc/client/Main.qc +++ b/qcsrc/client/Main.qc @@ -847,13 +847,26 @@ void Ent_Nagger() { float nags, i, j, b, f; - nags = ReadByte(); + nags = ReadByte(); // NAGS NAGS NAGS NAGS NAGS NAGS NADZ NAGS NAGS NAGS if(!(nags & 4)) { if(vote_called_vote) strunzone(vote_called_vote); vote_called_vote = string_null; + vote_active = 0; + } + else + { + vote_active = 1; + } + + if(nags & 64) + { + vote_yescount = ReadByte(); + vote_nocount = ReadByte(); + vote_needed = ReadByte(); + vote_highlighted = ReadChar(); } if(nags & 128) @@ -987,6 +1000,7 @@ void(float bIsNewEntity) CSQC_Ent_Update = case ENT_CLIENT_ACCURACY: Ent_ReadAccuracy(); break; case ENT_CLIENT_AUXILIARYXHAIR: Net_AuXair2(bIsNewEntity); break; case ENT_CLIENT_TURRET: ent_turret(); break; + case ENT_CLIENT_DAMAGEEFFECT: Ent_DamageEffect(); break; default: //error(strcat(_("unknown entity type in CSQC_Ent_Update: %d\n"), self.enttype)); error(sprintf(_("Unknown entity type in CSQC_Ent_Update (enttype: %d, edict: %d, classname: %s)\n"), self.enttype, num_for_edict(self), self.classname)); @@ -1300,22 +1314,6 @@ void Net_ReadPingPLReport() playerslots[e].ping_movementloss = ml / 255.0; } -void Net_VoteDialog(float highlight) { - if(highlight) { - vote_highlighted = ReadByte(); - return; - } - - vote_yescount = ReadByte(); - vote_nocount = ReadByte(); - vote_needed = ReadByte(); - vote_active = 1; -} - -void Net_VoteDialogReset() { - vote_active = 0; -} - void Net_Notify() { float type; type = ReadByte(); @@ -1328,6 +1326,17 @@ void Net_Notify() { { HUD_Centerprint(ReadString(), ReadString(), ReadShort(), ReadByte()); } + else if(type == CSQC_CENTERPRINT_GENERIC) + { + float id; + string s; + id = ReadByte(); + s = ReadString(); + if (id != 0 && s != "") + centerprint_generic(id, s, ReadByte(), ReadByte()); + else + centerprint_generic(id, s, 0, 0); + } } void Net_WeaponComplain() { @@ -1385,14 +1394,6 @@ float CSQC_Parse_TempEntity() Net_TeamNagger(); bHandled = true; break; - case TE_CSQC_VOTE: - Net_VoteDialog(ReadByte()); - bHandled = true; - break; - case TE_CSQC_VOTERESET: - Net_VoteDialogReset(); - bHandled = true; - break; case TE_CSQC_LIGHTNINGARC: Net_ReadLightningarc(); bHandled = true;