[nexuiz-commits] r6577 - trunk/data/qcsrc/server

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Thu Apr 23 10:50:58 EDT 2009


Author: div0
Date: 2009-04-23 10:50:57 -0400 (Thu, 23 Apr 2009)
New Revision: 6577

Modified:
   trunk/data/qcsrc/server/waypointsprites.qc
Log:
improve waypointsprites for speccers


Modified: trunk/data/qcsrc/server/waypointsprites.qc
===================================================================
--- trunk/data/qcsrc/server/waypointsprites.qc	2009-04-23 14:18:27 UTC (rev 6576)
+++ trunk/data/qcsrc/server/waypointsprites.qc	2009-04-23 14:50:57 UTC (rev 6577)
@@ -163,7 +163,13 @@
 {
 	// this is not in SendEntity because it shall run every frame, not just every update
 
-	return self.waypointsprite_visible_for_player(other);
+	// make spectators see what the player would see
+	entity e;
+	e = other;
+	if(e.classname == "spectator")
+		e = e.enemy;
+
+	return self.waypointsprite_visible_for_player(e);
 }
 
 float WaypointSprite_SendEntity(entity to, float sendflags)



More information about the nexuiz-commits mailing list