Fix RCS1227
This commit is contained in:
@@ -1109,6 +1109,9 @@ dotnet_diagnostic.RCS1225.severity = warning
|
||||
# Add paragraph to documentation comment.
|
||||
dotnet_diagnostic.RCS1226.severity = warning
|
||||
|
||||
# Validate arguments correctly.
|
||||
dotnet_diagnostic.RCS1227.severity = warning
|
||||
|
||||
# Unnecessary explicit use of enumerator.
|
||||
dotnet_diagnostic.RCS1230.severity = warning
|
||||
|
||||
|
||||
@@ -1353,6 +1353,10 @@ namespace OpenRA
|
||||
throw new ArgumentOutOfRangeException(nameof(maxRange),
|
||||
$"The requested range ({maxRange}) cannot exceed the value of MaximumTileSearchRange ({Grid.MaximumTileSearchRange})");
|
||||
|
||||
return FindTilesInAnnulus();
|
||||
|
||||
IEnumerable<CPos> FindTilesInAnnulus()
|
||||
{
|
||||
for (var i = minRange; i <= maxRange; i++)
|
||||
{
|
||||
foreach (var offset in Grid.TilesByDistance[i])
|
||||
@@ -1363,6 +1367,7 @@ namespace OpenRA
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public IEnumerable<CPos> FindTilesInCircle(CPos center, int maxRange, bool allowOutsideBounds = false)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user