Refactor MobileInfo.CanEnterCell
This commit is contained in:
@@ -95,7 +95,7 @@ namespace OpenRA.Mods.RA.Move
|
||||
// This assumes that the SubCell does not change during the path traversal
|
||||
var tilesInRange = world.Map.FindTilesInCircle(targetCell, range.Range / 1024 + 1)
|
||||
.Where(t => (world.Map.CenterOfCell(t) - target).LengthSquared <= rangeSquared
|
||||
&& mi.CanEnterCell(self.World, self, t, null, true, true));
|
||||
&& mi.CanEnterCell(self.World, self, t));
|
||||
|
||||
// See if there is any cell within range that does not involve a cross-domain request
|
||||
// Really, we only need to check the circle perimeter, but it's not clear that would be a performance win
|
||||
|
||||
Reference in New Issue
Block a user