I was working on various projects that are interesting just to watch, for use as a sort of display, and one of the most recent ones was a version of
WireWorld.
WireWorld is a
cellular automaton that simulates basic electronics (wires and electrons), particularly fun to mess around with basic logic gates and such in.
Cellular automata are a fairly simple sort of simulation, in which the "world" is a grid of cells, each in one of a finite number of states. Then, depending on a set number of rules/conditions, each cell can change states.
One example of a fairly simple cellular automaton is
Conway's Game of Life. Cells in "Life" are either "alive" or "dead". A "dead" cell turns into an "alive" cell if there are exactly 3 "alive" cells next to it, and an "alive" cell turns into a dead cell if more than 3 or fewer than 2 "alive" cells are next to it. The resulting patterns can be very interesting to watch.
But I digress, the point of this topic wasn't to explain cellular automata, but to "advertise" a program I wrote to simulate them. After finishing the WireWorld program, I realized how simple it would be to turn it into a "Life" program, or any other cellular automaton. But, rather than hard-coding a bunch of different rule sets, I decided to design a program that would load a set of rules from an external file, so multiple rule sets could be made up fairly quickly, and without the need for programming experience, or re-compiling a program.
The result of my efforts, cirCA-Sim. cirCA-Sim is a Cellular Automata SIMulator, that uses CustomIzed Rules (lame, I know, but it's the best I could come up with). Rules are loaded from an XML file containing a list of cells and the rules for changing them. Then, a grid of cells is loaded either from a .txt or .bmp file, and the simulater runs one step at a time, once for each key-press. It's a very simple program, the interface is very simple. In fact, aside from the 3 keys used to load files and exit, and the use of any other key to step through the simulation, there isn't one. See the README.txt in the .zip file for further directions, and the XMLFORMAT.txt for details on the tags used in the rule files. Two rule files, one .txt format grid file, and two .bmp format grid files are included in the download, along with the windows binary, and the source-code.
Screenshots:
DOWNLOAD(531KB)- Added settings.ini file, which currently only loads resolution. However, there was a bug with resolution size before, so if you have any problems with the program starting up, try lowering the resolution.
- Added 5 new search patterns/neighborhoods, and fixed a bug regarding the original two, when the radius was higher than 2.
- Added mouse controls, both the menus and main screen can now be interacted with, see the README file for more information.
- Grids can now be saved from within the simulator by pressing the 's' key. See the README file for more information.
Not sure what I'm doing yet...
[/list]