From a5e87a7ffb0df1c65d19be0d698cf3034cceaef0 Mon Sep 17 00:00:00 2001 From: Mario Date: Wed, 16 Dec 2015 15:58:47 +1000 Subject: [PATCH] Make CSQC items much more accurately predicted --- qcsrc/server/t_items.qc | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/qcsrc/server/t_items.qc b/qcsrc/server/t_items.qc index 35fd87832..d25849533 100644 --- a/qcsrc/server/t_items.qc +++ b/qcsrc/server/t_items.qc @@ -174,6 +174,9 @@ NET_HANDLE(ENT_CLIENT_ITEM, bool isnew) self.drawmask = MASK_NORMAL; self.move_movetype = self.movetype = MOVETYPE_TOSS; self.draw = ItemDraw; + //self.move_flags |= FL_ITEM; + + bool use_bigsize = ReadByte(); self.fade_end = ReadShort(); self.fade_start = ReadShort(); @@ -215,6 +218,8 @@ NET_HANDLE(ENT_CLIENT_ITEM, bool isnew) precache_model(self.mdl); _setmodel(self, self.mdl); + + setsize(self, '-16 -16 0', (use_bigsize) ? '16 16 48' : '16 16 32'); } if(sf & ISF_COLORMAP) @@ -293,6 +298,8 @@ bool ItemSend(entity this, entity to, int sf) if(sf & ISF_MODEL) { + Pickup p = this.itemdef; + WriteByte(MSG_ENTITY, p.instanceOfPowerup || p.instanceOfHealth || p.instanceOfArmor); WriteShort(MSG_ENTITY, self.fade_end); WriteShort(MSG_ENTITY, self.fade_start); -- 2.39.2