From 866ee9e66df7215467842264860c37628df8b795 Mon Sep 17 00:00:00 2001 From: terencehill Date: Sat, 13 May 2017 22:22:01 +0200 Subject: [PATCH] If for some reason a bot selects teleport/jumppad/warpzone origin as route destination automatically add teleport/jumppad/warpzone destination to the route --- qcsrc/server/bot/default/navigation.qc | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/qcsrc/server/bot/default/navigation.qc b/qcsrc/server/bot/default/navigation.qc index 14d944623..59bc8dba8 100644 --- a/qcsrc/server/bot/default/navigation.qc +++ b/qcsrc/server/bot/default/navigation.qc @@ -928,6 +928,13 @@ bool navigation_routetogoal(entity this, entity e, vector startposition) if (!e) return false; + if(e.wpflags & WAYPOINTFLAG_TELEPORT) + { + // force teleport destination as route destination + e.wp00.enemy = e; + e = e.wp00; + } + this.goalentity = e; // put the entity on the goal stack -- 2.39.2