Fast Micro AI: fix attack_filter when excluding leader

“canrecruit = nil” does not give the same result as “canrecruit =
false” in a standard unit filter.
This commit is contained in:
mattsc 2016-10-20 09:31:44 -07:00
parent 41672422a6
commit 25eb3dd20f

View file

@ -31,6 +31,7 @@ function ca_fast_attack_utils.get_avoid_map(cfg)
end
local function attack_filter(which, filter, is_leader)
if (is_leader == nil) then is_leader = false end
if (which == 'leader') then
which = 'own'
is_leader = true