mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-04 10:31:17 +00:00
Make escorts not wander after messenger killed
This commit is contained in:
parent
341ebfb394
commit
a14dc53efe
@ -242,6 +242,10 @@ return {
|
||||
-----------------------
|
||||
|
||||
function messenger_escort:other_move_eval()
|
||||
local messenger = wesnoth.get_units{ side = wesnoth.current.side, id = id }[1]
|
||||
if not messenger then
|
||||
return 0
|
||||
end
|
||||
-- Move other units close to messenger, and in between messenger and enemies
|
||||
-- The messenger has moved at this time, so we don't need to exclude him
|
||||
local my_units = wesnoth.get_units{ side = wesnoth.current.side, formula = '$this_unit.moves > 0' }
|
||||
|
Loading…
x
Reference in New Issue
Block a user