// I/F public void ForEach(Action<IntVector3> action) { for (int z = -radius; z < radius; z++) { for (int y = -radius; y < radius; y++) { for (int x = -radius; x < radius; x++) { var point = new IntVector3(x, y, z); var lengthSquared = point.LengthSquared(); if (lengthSquared <= radiusSquared) action(point); } } } }
// I/F public void ForEach(Action <IntVector3> action) { for (int z = -radius; z < radius; z++) { for (int y = -radius; y < radius; y++) { for (int x = -radius; x < radius; x++) { var point = new IntVector3(x, y, z); var lengthSquared = point.LengthSquared(); if (lengthSquared <= radiusSquared) { action(point); } } } } }