Wolves Micro AI: fix problem with target unit filtering
This commit is contained in:
parent
50146bc509
commit
cf731dd923
1 changed files with 4 additions and 1 deletions
|
@ -11,7 +11,10 @@ local function get_wolves(cfg)
|
|||
end
|
||||
|
||||
local function get_prey(cfg)
|
||||
local prey = AH.get_attackable_enemies(H.get_child(cfg, "filter_second"))
|
||||
-- Note: we cannot pass H.get_child() directly to AH.get_attackable_enemies()
|
||||
-- as the former returns two values and the latter takes optional arguments
|
||||
local filter_second = H.get_child(cfg, "filter_second")
|
||||
local prey = AH.get_attackable_enemies(filter_second)
|
||||
return prey
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue