From 42d0d3b0c1710e6eb7689a8a26785243832d0903 Mon Sep 17 00:00:00 2001 From: mand1nga Date: Tue, 9 Aug 2011 00:45:46 -0300 Subject: [PATCH] Ignore destructed devices (doesn't fully work yet) --- qcsrc/server/bot/havocbot/role_assault.qc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/qcsrc/server/bot/havocbot/role_assault.qc b/qcsrc/server/bot/havocbot/role_assault.qc index e5e3bdb6c..57380dd03 100644 --- a/qcsrc/server/bot/havocbot/role_assault.qc +++ b/qcsrc/server/bot/havocbot/role_assault.qc @@ -36,8 +36,9 @@ void havocbot_goalrating_ast_targets(float ratingscale) { if(tod.classname == "target_objective_decrease") { - if(tod.enemy.health < ASSAULT_VALUE_INACTIVE) + if(tod.enemy.health > 0 && tod.enemy.health < ASSAULT_VALUE_INACTIVE) { + dprint(etos(tod.enemy),"\n"); found = TRUE; break; } @@ -87,7 +88,10 @@ void havocbot_goalrating_ast_targets(float ratingscale) if(checkpvs(self.view_ofs,ad)) if(checkpvs(self.view_ofs,best)) + { + // dprint("increasing attack time for this target\n"); self.havocbot_attack_time = time + 2; + } } } } -- 2.39.2