We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 33c1d10 + e588184 commit 80f70beCopy full SHA for 80f70be
Essentials/Commands/CleanupModule.cs
@@ -70,10 +70,11 @@ private IEnumerable<MyCubeGrid> ScanConditions(IReadOnlyList<string> args)
70
}
71
72
73
- foreach (var grid in MyEntities.GetEntities().OfType<MyCubeGrid>())
+ foreach (var group in MyCubeGridGroups.Static.Logical.Groups)
74
{
75
- if (conditions.TrueForAll(func => func(grid)))
76
- yield return grid;
+ if (group.Nodes.All(grid => conditions.TrueForAll(func => func(grid.NodeData))))
+ foreach (var grid in group.Nodes)
77
+ yield return grid.NodeData;
78
79
80
0 commit comments