From: terencehill Date: Mon, 13 Nov 2017 19:15:35 +0000 (+0100) Subject: Fix bug in nearest waypoint search I introduced in 01376c61cd X-Git-Tag: xonotic-v0.8.5~2378^2~20 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=bac725960ca2427a7fec79cb0624ea20d3bee859;p=xonotic%2Fxonotic-data.pk3dir.git Fix bug in nearest waypoint search I introduced in 01376c61cd --- diff --git a/qcsrc/server/bot/default/navigation.qc b/qcsrc/server/bot/default/navigation.qc index c9ebc0755..71666aacd 100644 --- a/qcsrc/server/bot/default/navigation.qc +++ b/qcsrc/server/bot/default/navigation.qc @@ -967,7 +967,7 @@ entity navigation_findnearestwaypoint_withdist_except(entity ent, float walkfrom tracewalk_dest, tracewalk_dest_height, walkfromwp, bestdist)) { if (walkfromwp) - bestdist = vlen(tracewalk_dest - org); + bestdist = vlen(tracewalk_dest - v); else bestdist = vlen(v - org); best = it;