I am trying to make a multi-state CA similar to the image above. The code was shared on the website but when I copied and pasted it I only got coloured points, not coloured cells, as in the image above. Can someone help me figure out what is going on? The code is long, but I can't tell what parts are actually doing something and what's fat. Thanks
class WuXingCell
{
float[] element;
};
int worldScale = 8;
int worldSize = 64;
int mode = 1;
WuXingCell[][] world;
WuXingCell[][] nextWorld;
color[] WuXingColor;
float waterLevel = .25;
int dayBand = 0;
float natLog = 0.36787944118;
float eLog = 2.7182818284;
float growRate = .2;
float destroyRate = .11;
float insultRate = .1;
float growThresh = .1;
float destroyThresh = .2;
float insultThresh = .4;
float[] elementFlow; //how much is moved when it erodes
float[] elementStrength; //when element decides to erode
float[] elementDistScale; //distance from strongest points
float[] elementReactivity;
int dominantElement = 0;
float seaLevel = 0;
int water = 0; //we do this so the code is more readable, also showing the cyclical order