what about... making a 'broadcast' simulation: there is a single source of the signal to change animation, each highlighted in a different color. All nodes have as part of their class a spot to store current thought. All nodes can only 'hear' message from a specified distance. upon hearing, they are capable of transmitting. The broadcast range could be so close that theyd essentially have to 'touch' to comm. ! :) i like it, i'm gonna do it.
...The story always begins with an idea in a single marble's head. (Preach)
(You can select which one by clicking with mouse)
The Master Marble has one of four possible thoughts in it's head. This is selected by pressing first letter of pattern:
[O]rbit, [S]piral, [R]andom, [W]hirlwind.
Up and Down keys control animation speed.
..As the marbles make contact with eachother they share whatever idea theyve heard most recently.
A little explosion signifies the idea having been transferred from one marble to the next.
This creates a bond between them. Each idea has a different color.
As they move around bumping into one another the idea spreads and spreads until, usually, everyone is thinking the same thing. (Though, play with it long enough and theres ways to have different groups stay formed) The counts of each idea are seen at the bottom.
I guess the moral of the story is...marbles are impressionable? :D
I hope you enjoy the pretty visuals and the code itself. Fork it and make them reproduce or raise kids or start wars over which spinny pattern is the best
oh and PS: there's at least one easter-egg pattern i didnt mention ;)
it requires pygame
and thats literally it.
pip3 install pygame