diff --git a/OpenRA.Mods.RA/Move/Mobile.cs b/OpenRA.Mods.RA/Move/Mobile.cs index a5117c215b..35b198f81c 100755 --- a/OpenRA.Mods.RA/Move/Mobile.cs +++ b/OpenRA.Mods.RA/Move/Mobile.cs @@ -229,15 +229,7 @@ namespace OpenRA.Mods.RA.Move public CPos NearestMoveableCell(CPos target, int minRange, int maxRange) { - if (CanEnterCell(target)) - return target; - - foreach (var tile in self.World.FindTilesInCircle(target, maxRange)) - if (CanEnterCell(tile)) - return tile; - - // Couldn't find a cell - return target; + return NearestCell(target, CanEnterCell, minRange, maxRange); } public CPos NearestCell(CPos target, Func check, int minRange, int maxRange)