In regards to fleeing, yes it is not well done at the moment. I disagree that fleeing doesn't add anything to the game, though. Fleeing is an excellent strategy (used by players) to cooldown talents/inscriptions, and tactical AI should be able to do that, too. I think infinite fleeing (ignoring natural health regeneration) is indeed a problem. What if fleeing was changed to flee if and only if there are talents cooling down?
Untested diff:
Code: Select all
diff --git a/game/modules/tome/ai/tactical.lua b/game/modules/tome/ai/tactical.lua
index 3e2b1ce..55058c7 100644
--- a/game/modules/tome/ai/tactical.lua
+++ b/game/modules/tome/ai/tactical.lua
@@ -37,7 +37,7 @@ local checkLOS = function(sx, sy, tx, ty)
 end
 
 local canFleeDmapKeepLos = function(self)
-       if self.never_move then return false end -- Dont move, dont flee
+       if self.never_move then return false end -- Don't move, don't flee
        if self.ai_target.actor then
                local act = self.ai_target.actor
                local c = act:distanceMap(self.x, self.y)
@@ -264,8 +264,9 @@ newAI("use_tactical", function(self)
                        want.closein = 1 + target_dist / 2
                end
 
-               -- Need escaping... allow escaping even if there isn't a talent so we can flee
-               if target_dist and (avail.escape or canFleeDmapKeepLos(self)) then
+               -- Need escaping... allow escaping even if there isn't a talent so we can flee to cooldown
+               
+               if target_dist and (avail.escape or (next(self.talents_cd) and canFleeDmapKeepLos(self))) then
                        want.escape = need_heal / 2
                        if self.ai_tactic.safe_range and target_dist < self.ai_tactic.safe_range then want.escape = want.escape + self.ai_tactic.safe_range / 2 end
                end


