]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix waypoint lookup on the waypoint hardwiring code
authormand1nga <mand1nga@xonotic.org>
Sun, 7 Aug 2011 21:06:07 +0000 (18:06 -0300)
committermand1nga <mand1nga@xonotic.org>
Sun, 7 Aug 2011 21:06:07 +0000 (18:06 -0300)
qcsrc/server/bot/waypoints.qc

index d2db7cd23e503591d22cba8000b38318299b47a3..2fe2a09d79a2d1d5bf2beb533e35ebead738fef8 100644 (file)
@@ -23,7 +23,7 @@ entity waypoint_spawn(vector m1, vector m2, float f)
        setsize(w, m1 - w.origin, m2 - w.origin);
        if (vlen(w.size) > 0)
                w.wpisbox = TRUE;
-       
+
        if(!w.wpisbox)
        {
                setsize(w, PL_MIN - '1 1 0', PL_MAX + '1 1 0');
@@ -496,11 +496,11 @@ void waypoint_load_links_hardwired()
                // Search "from" waypoint
                if(wp_from.origin!=wp_from_pos)
                {
-                       wp_from = findradius(wp_from_pos, 1);
+                       wp_from = findradius(wp_from_pos, 5);
                        found = FALSE;
                        while(wp_from)
                        {
-                               if(vlen(wp_from.origin-wp_from_pos)<1)
+                               if(vlen(wp_from.origin-wp_from_pos)<5)
                                if(wp_from.classname == "waypoint")
                                {
                                        found = TRUE;
@@ -517,11 +517,11 @@ void waypoint_load_links_hardwired()
                }
 
                // Search "to" waypoint
-               wp_to = findradius(wp_to_pos, 1);
+               wp_to = findradius(wp_to_pos, 5);
                found = FALSE;
                while(wp_to)
                {
-                       if(vlen(wp_to.origin-wp_to_pos)<1)
+                       if(vlen(wp_to.origin-wp_to_pos)<5)
                        if(wp_to.classname == "waypoint")
                        {
                                found = TRUE;