mirror of
https://github.com/vcmi/vcmi.git
synced 2025-02-09 13:14:02 +02:00
Merge pull request #4708 from IvanSavenko/subterra_pathfinder_fix
Fixes pathfinding via subterranean gates located on right edge of map
This commit is contained in:
commit
f17fe6a48e
@ -964,7 +964,7 @@ std::vector<ObjectInstanceID> CGameInfoCallback::getVisibleTeleportObjects(std::
|
||||
vstd::erase_if(ids, [&](const ObjectInstanceID & id) -> bool
|
||||
{
|
||||
const auto * obj = getObj(id, false);
|
||||
return player != PlayerColor::UNFLAGGABLE && (!obj || !isVisible(obj->pos, player));
|
||||
return player != PlayerColor::UNFLAGGABLE && (!obj || !isVisible(obj->visitablePos(), player));
|
||||
});
|
||||
return ids;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user