From: terencehill Date: Thu, 29 Nov 2018 15:05:48 +0000 (+0100) Subject: Bot AI: fix broken aim direction when bot executes user commands such as bot_cmd... X-Git-Tag: xonotic-v0.8.5~1705^2~6 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=c329c40a3e9a0487505c87286671cfdcb5cae8bf;p=xonotic%2Fxonotic-data.pk3dir.git Bot AI: fix broken aim direction when bot executes user commands such as bot_cmd 1 moveto 'x y z' --- diff --git a/qcsrc/server/bot/default/havocbot/havocbot.qc b/qcsrc/server/bot/default/havocbot/havocbot.qc index bb6c15c52..1dfd72bf0 100644 --- a/qcsrc/server/bot/default/havocbot/havocbot.qc +++ b/qcsrc/server/bot/default/havocbot/havocbot.qc @@ -31,6 +31,8 @@ void havocbot_ai(entity this) if(this.draggedby) return; + this.bot_aimdir_executed = false; + if(bot_execute_commands(this)) return; @@ -106,8 +108,6 @@ void havocbot_ai(entity this) havocbot_aim(this); lag_update(this); - this.bot_aimdir_executed = false; - if (this.bot_aimtarg) { this.aistatus |= AI_STATUS_ATTACKING;