I would like to create an array of 100 randomly chosen colors that I can pick from throughout my “draw” code.
If I use
color[] colors = new color[100];
for (int i = 0; i<100; i++) {
colors[i]= color(random(255), random(255), random(255));
}
inside draw, the list is updated over and over (which I don’t want). If I use the same code in setup, I can’t access the variable “colors” in draw. If I use the same code in between setup and draw, I get an error “expecting EOF, found ‘for’”.
Hey, I saw a lot of your replies I am a beginner and you seem to enjoy helping new people. I would appreciate it if you could help me. I just posted a question, is there a way I can personally talk to you regarding my issue or visit here: *URGENT* Assistance with Drawing Program