]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
make CheckProjectileImpact more consistent
authorRudolf Polzer <divVerent@xonotic.org>
Sun, 26 Jun 2011 10:28:10 +0000 (12:28 +0200)
committerRudolf Polzer <divVerent@xonotic.org>
Sun, 26 Jun 2011 10:28:10 +0000 (12:28 +0200)
qcsrc/warpzonelib/server.qc

index 7d1780b0fe7cb972dbbb4f3eb10b128429b0d439..192bf830acc17d74f6aacc400fa0d70530d9ca4b 100644 (file)
@@ -264,6 +264,8 @@ float WarpZone_Camera_Send(entity to, float sendflags)
 
 float WarpZone_CheckProjectileImpact()
 {
+       // FIXME make this use WarpZone_Teleport
+
        // if self hit a warpzone, abort
        vector o0, v0, a0;
        float mpd, pd, dpd;
@@ -305,9 +307,15 @@ float WarpZone_CheckProjectileImpact()
                        return 0;
                }
        }
+
        WarpZone_RefSys_Add(self, wz);
+
+       BITXOR_ASSIGN(self.effects, EF_TELEPORT_BIT);
+       WarpZone_PostTeleportPlayer_Callback(self);
+
        WarpZone_StoreProjectileData(self);
        self.warpzone_teleport_time = time;
+       self.warpzone_teleport_zone = wz;
 
        return +1;
 }