Cube[] allCubes = new Cube[numCubes];
float numberofCircles = 15;
float angle = radians (300 / numberofCircles);
float offset = radians (90);
for (int cubeIndex = 0; cubeIndex < numCubes; cubeIndex++) {
allCubes[cubeIndex] = new Cube();
allCubes[cubeIndex].cubeColor = color (random(255), random(0), random(0));
directionalLight(126, 126, 126, 0, 0, -1);
for (int i = 1; i <= numberofCircles; i++) {
float x = cos(angle *i + offset) * distance + width/2;
float y = sin(angle *i + offset) * distance + height/2;
ellipse (x, y, 10+i, 10+i);
for (int i = 1; i <= numberofCircles; i++) {
float x = cos(angle *i - offset) * (distance+100) + width/2;
float y = sin(angle *i - offset) * (distance+100) + height/2;
ellipse (x, y, 20+i, 20+i);
for (int i = 1; i <= numberofCircles; i++) {
float x = cos(angle *i + offset) * (distance+250) + width/2;
float y = sin(angle *i + offset) * (distance+250) + height/2;
ellipse (x, y, 60+i, 60+i);
for (int i = 1; i <= numberofCircles; i++) {
float x = cos(angle *i - offset) * (distance+550) + width/2;
float y = sin(angle *i - offset) * (distance+550) + height/2;
ellipse (x, y, 120+i, 120+i);
for (int i = 1; i <= numberofCircles; i++) {
float x = cos(angle *i - offset) * (distance+1050) + width/2;
float y = sin(angle *i - offset) * (distance+1050) + height/2;
ellipse (x, y, 200-i, 200-i);
offset = offset + counter;
translate(width/2, height/2, 0);
for (int cubeIndex = 0; cubeIndex < numCubes; cubeIndex++) {
allCubes[cubeIndex].display();