From: terencehill Date: Mon, 7 Aug 2017 13:00:52 +0000 (+0200) Subject: Require at least half bot's body is inside teleport waypoint before heading to telepo... X-Git-Tag: xonotic-v0.8.5~2378^2~90 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=2f3c32bb6372a436aad4a7e23fea91378d2ce740;p=xonotic%2Fxonotic-data.pk3dir.git 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 --- 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;