Being one of the more complex games I’ve created, I thought it would be interesting to take a peek under the hood and see what exactly is going on.
The game itself is very simple. It asks the player to answer a series of questions that are written to be very surrealist and vague; every answer is indexed and then compared to a series of variable arrays. These variables control different aspects of the simulation, such as the trail length and the diffuse rate of the individual agents that make up each simulation (which I will call “slimes” for simplicity).
There are variables that control the entire simulation, and there are variables that only apply to a specific group by “species”. Depending on the player choice, there can be anywhere from one to three species in a single simulation. The species variables are assigned independently of each other to further separate their identities. The questions are not repeats of each other, though they’re essentially asking the same things.
Variables that affect the entire simulation
| Variable Name | What it does |
| Mode | The way that agents spawn onto the canvas |
| TrailWeight | How “much” of a trail individual agents leave |
| DecayRate | How quickly the slime trails disappear |
| DiffuseRate | How much the slime trails blur into the background |
| SpeciesNum | The number of species present in the simulation |
| SpeciesIndex | The current species we will be assigning variables to |
Variables that affect individual species
| Variable Name | What it does |
| moveSpeed | How quickly individual agents can move |
| turnSpeed | How quickly individual agents can turn left or right |
| sensorAngleSpacing | How “wide” individual agents can sense around them |
| sensorOffsetDst | How far the sensors are from the individual agent |
| sensorSize | The size of individual agents’ sensors |
| tone | The color group (pastel, jewel tones, very bright) |
| colour | The hue (red, orange, yellow, green, blue, purple, white) |