From 2f3c32bb6372a436aad4a7e23fea91378d2ce740 Mon Sep 17 00:00:00 2001 From: terencehill Date: Mon, 7 Aug 2017 15:00:52 +0200 Subject: [PATCH] Require at least half bot's body is inside teleport waypoint before heading to teleport waypoint's origin, fixes bot occasionally getting stuck on certain teleports --- qcsrc/server/bot/default/havocbot/havocbot.qc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qcsrc/server/bot/default/havocbot/havocbot.qc b/qcsrc/server/bot/default/havocbot/havocbot.qc index dde996d19..e98bd117c 100644 --- a/qcsrc/server/bot/default/havocbot/havocbot.qc +++ b/qcsrc/server/bot/default/havocbot/havocbot.qc @@ -766,7 +766,7 @@ void havocbot_movetogoal(entity this) // in case bot ends up inside the teleport waypoint without touching // the teleport itself, head to the teleport origin - if(this.goalcurrent.wpisbox && boxesoverlap(this.goalcurrent.absmin, this.goalcurrent.absmax, this.absmin, this.absmax)) + if(this.goalcurrent.wpisbox && boxesoverlap(this.goalcurrent.absmin, this.goalcurrent.absmax, this.origin + eZ * this.mins.z, this.origin + eZ * this.maxs.z)) { bunnyhop_forbidden = true; destorg = this.goalcurrent.origin; -- 2.39.2