[nexuiz-commits] r8645 - trunk/data/qcsrc/client
DONOTREPLY at icculus.org
DONOTREPLY at icculus.org
Sat Feb 13 11:21:09 EST 2010
Author: div0
Date: 2010-02-13 11:21:08 -0500 (Sat, 13 Feb 2010)
New Revision: 8645
Modified:
trunk/data/qcsrc/client/interpolate.qc
trunk/data/qcsrc/client/interpolate.qh
trunk/data/qcsrc/client/projectile.qc
Log:
REALLY fix the rocket trail interpolation
Modified: trunk/data/qcsrc/client/interpolate.qc
===================================================================
--- trunk/data/qcsrc/client/interpolate.qc 2010-02-13 16:01:09 UTC (rev 8644)
+++ trunk/data/qcsrc/client/interpolate.qc 2010-02-13 16:21:08 UTC (rev 8645)
@@ -4,6 +4,11 @@
.vector iforward1, iforward2;
.vector iup1, iup2;
.float itime1, itime2;
+void InterpolateOrigin_Reset()
+{
+ self.iflags &~= (IFLAG_PREVALID | IFLAG_VALID);
+ self.itime1 = self.itime2 = 0;
+}
void InterpolateOrigin_Note()
{
float dt;
Modified: trunk/data/qcsrc/client/interpolate.qh
===================================================================
--- trunk/data/qcsrc/client/interpolate.qh 2010-02-13 16:01:09 UTC (rev 8644)
+++ trunk/data/qcsrc/client/interpolate.qh 2010-02-13 16:21:08 UTC (rev 8645)
@@ -12,5 +12,8 @@
// call this AFTER receiving an entity update
void InterpolateOrigin_Note();
+// call this when the entity got teleported, before InterpolateOrigin_Note
+void InterpolateOrigin_Reset();
+
// call this BEFORE drawing
void InterpolateOrigin_Do();
Modified: trunk/data/qcsrc/client/projectile.qc
===================================================================
--- trunk/data/qcsrc/client/projectile.qc 2010-02-13 16:01:09 UTC (rev 8644)
+++ trunk/data/qcsrc/client/projectile.qc 2010-02-13 16:21:08 UTC (rev 8645)
@@ -1,3 +1,4 @@
+.vector iorigin1, iorigin2;
.float spawntime;
.vector trail_oldorigin;
.float trail_oldtime;
@@ -217,8 +218,9 @@
if(time == self.spawntime || (self.count & 0x80) || (f & 0x10))
{
- print("TELE\n");
self.trail_oldorigin = self.origin;
+ if(!(self.count & 0x80))
+ InterpolateOrigin_Reset();
}
if(f & 0x20)
More information about the nexuiz-commits
mailing list