int numStars = 250 ; Star[] star = new Star[numStars]; void setup() { // set window & colour options size(400,400); background (255); stroke(140,140,115); noFill(); fill (222,222,197,20); noStroke(); // create stars for (int i=0;i500){ z=-2000; } // update star rotation, reset if greater then 2xPI ax-=ix ; ay+=iy ; if (ax>TWO_PI) {ax=0;} if (ay>TWO_PI) {ay=0;} translate(x,y,z); // move star to new position rotateX(ax);rotateY(ay); // rotate object box(30); // draw object pop(); } }