From: TimePath Date: Sun, 29 Nov 2015 05:24:51 +0000 (+1100) Subject: entcs: de-jitter X-Git-Tag: xonotic-v0.8.2~1610 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=4409c6e68922316303de5f1d7fb45725c7652e19;p=xonotic%2Fxonotic-data.pk3dir.git entcs: de-jitter --- diff --git a/qcsrc/client/shownames.qc b/qcsrc/client/shownames.qc index f13efdde0..e217e2d31 100644 --- a/qcsrc/client/shownames.qc +++ b/qcsrc/client/shownames.qc @@ -168,6 +168,7 @@ void Draw_ShowNames_All() LL_EACH(shownames_ent, true, LAMBDA( entity entcs = entcs_receiver(i); if (!entcs) continue; + WITH(entity, self, entcs, entcs.think()); if (entcs.m_entcs_private) { it.healthvalue = entcs.healthvalue; diff --git a/qcsrc/common/ent_cs.qc b/qcsrc/common/ent_cs.qc index c07fad0d5..a3d3cc8be 100644 --- a/qcsrc/common/ent_cs.qc +++ b/qcsrc/common/ent_cs.qc @@ -122,23 +122,19 @@ void entcs_think() { SELFPARAM(); - this.nextthink = time; entity e = CSQCModel_server2csqc(this.sv_entnum); - bool exists = e != NULL; - if (exists) + if (e == NULL) { - this.has_origin = true; - this.origin = e.origin; - // `cl_forceplayermodels 1` sounds will be wrong until the player has been in the PVS, but so be it - if (this.model != e.model) - { - if (this.model) strunzone(this.model); - this.model = strzone(e.model); - } + this.has_origin = this.has_sv_origin; + return; } - else + this.has_origin = true; + this.origin = e.origin; + // `cl_forceplayermodels 1` sounds will be wrong until the player has been in the PVS, but so be it + if (this.model != e.model) { - this.has_origin = this.has_sv_origin; + if (this.model) strunzone(this.model); + this.model = strzone(e.model); } } @@ -150,7 +146,6 @@ this.classname = "entcs_receiver"; this.entremove = Ent_RemoveEntCS; this.think = entcs_think; - this.nextthink = time; } InterpolateOrigin_Undo(this); int sf = ReadShort(); @@ -163,6 +158,7 @@ entcs_receiver(this.sv_entnum, this); this.iflags |= IFLAG_ORIGIN; InterpolateOrigin_Note(this); + this.think(); return true; }