]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix waypoints marked as pure but still linked to the world and with collision testing...
authorterencehill <piuntn@gmail.com>
Sun, 19 Feb 2023 15:23:58 +0000 (16:23 +0100)
committerterencehill <piuntn@gmail.com>
Sun, 19 Feb 2023 15:23:58 +0000 (16:23 +0100)
qcsrc/lib/warpzone/common.qc
qcsrc/server/bot/default/waypoints.qc

index 46710db66c92c041fd447a2ea3e00c2edde83356..0c85d4a088522cce87bbd09fa6b7a2f95ff4f60f 100644 (file)
@@ -582,6 +582,7 @@ bool WarpZoneLib_BadEntity(entity e)
                case "weaponentity":
                case "exteriorweaponentity":
                case "sprite_waypoint":
+               case "waypoint":
                case "spawnfunc":
                case "weaponchild":
                case "chatbubbleentity":
index c1afab673f8d358d35bb04c6c6f97bca4f9c38ee..88ea34de221213c563f1d503b82c6837c3046349 100644 (file)
@@ -453,11 +453,7 @@ entity waypoint_spawn(vector m1, vector m2, float f)
        w.wpflags = f;
        w.solid = SOLID_TRIGGER;
        w.createdtime = time;
-       w.origin = (m1 + m2) * 0.5;
-       if (waypointeditor_enabled)
-               setorigin(w, w.origin);
-       else // don't link into the world, only bots are aware of waypoints
-               make_pure(w);
+       setorigin(w, (m1 + m2) * 0.5);
        setsize(w, m1 - w.origin, m2 - w.origin);
        if (w.size)
                w.wpisbox = true;
@@ -1295,10 +1291,7 @@ spawnfunc(waypoint)
 {
        IL_PUSH(g_waypoints, this);
 
-       if (waypointeditor_enabled)
-               setorigin(this, this.origin);
-       else
-               make_pure(this);
+       setorigin(this, this.origin);
        // schedule a relink after other waypoints have had a chance to spawn
        waypoint_clearlinks(this);
        //waypoint_schedulerelink(this);