From: terencehill Date: Thu, 5 May 2022 09:54:18 +0000 (+0200) Subject: Bot AI: don't attack players who finished the race X-Git-Tag: xonotic-v0.8.5~45 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=7c892551468cf052480c8ba3004d9a279c1ad838;p=xonotic%2Fxonotic-data.pk3dir.git Bot AI: don't attack players who finished the race --- diff --git a/qcsrc/server/race.qc b/qcsrc/server/race.qc index 4ecda0a9a..545bdad27 100644 --- a/qcsrc/server/race.qc +++ b/qcsrc/server/race.qc @@ -502,6 +502,9 @@ void race_SendTime(entity e, float cp, float t, float tvalid) { CS(e).race_completed = 1; MAKE_INDEPENDENT_PLAYER(e); + if(e.bot_attack) + IL_REMOVE(g_bot_targets, e); + e.bot_attack = false; Send_Notification(NOTIF_ALL, NULL, MSG_INFO, INFO_RACE_FINISHED, e.netname); ClientData_Touch(e); }