// A simple program to demonstrate playing around // with simple objects and simple interactions // by Brock Craft // Modified 6 April 2005 // // Warning: this code ain't elegant - but it works! RectObject[] r1; int num = int(10+random(20)); // makes between 10 and 30 objects PImage b; void setup() { size(647,400); //golden ratio - cuz I like it. stroke(205); colorMode(HSB); frameRate(30); PFont f = loadFont("hooge_06_66.vlw"); textFont(f, 10); textAlign(LEFT); // stuff an array with a bunch of Rectangular objects r1 = new RectObject[num]; for(int i=0; i0){ a=a-10; } } void plusSpeed(){ sp=sp+1; } void lessSpeed(){ if (sp>0){ sp=sp-1; } } void plusSize(){ s=s+10; } void lessSize(){ if (s>0){ s=s-10; } } // this clears the screen and starts over if the mouse is clicked void initialize(){ for(int i=0; i