Redirect units unstored to greater than map width/height...

...to the recall list. (fix for bug #17792)
This commit is contained in:
Anonymissimus 2011-02-28 19:26:22 +00:00
parent d8642755d7
commit f9848ab2c9

View file

@ -2024,7 +2024,7 @@ WML_HANDLER_FUNCTION(unstore_unit, /*event_info*/, cfg)
preferences::encountered_units().insert(u.type_id());
map_location loc = cfg_to_loc(
(cfg.has_attribute("x") && cfg.has_attribute("y")) ? cfg : vconfig(var));
if(loc.valid()) {
if(resources::game_map->on_board(loc)) {
if (cfg["find_vacant"].to_bool()) {
const unit* pass_check = NULL;
if (cfg["check_passability"].to_bool(true)) pass_check = &u;