 -= WHAT IS 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.


 -= USING CIRCA-SIM =-
If you haven't already, run the cirCA-Sim.exe file.  A screen is displayed that allows you to, using the arrow and enter keys or the mouse, select an initial rules file (.xml).  Once it's loaded the rules, press the [l] (L) key to open a screen that will allow you to select a grid file (.txt or .bmp) to load.  Once the grid file has loaded, press any key to step through the simulation.  At any time, you can press [ESC] to quit, [l] to load/reload a grid file, or [r] to load a rules file.

You can also edit the grid using the mouse (mouse wheel to select a cell state/type, left click to place it, right click places whatever the default cell is), and save the grid to a .bmp file with the [s] key.  Currently, it automatically saves it to "savefile.bmp", so make sure you rename or move the file before you save again, or it will be overwritten.


 -= WRITING RULE FILES =-
The rule files for cirCA-Sim use the .xml format.  If you are not familiar with the .xml format, you may want to make a quick search on google, and at least gain some understanding before editing the rule files.  For a list of tags used in rule XML files, see the XMLFORMAT.txt file.


 -= WRITING GRID FILES =-

 :The .TXT Method:
A .txt grid file is the most basic (although probably not the easiest to use) file that can be used to store a grid.  The first two lines each have a number, representing the width and height (respectively) of the grid (measured in cells).  After that, the file contains numbers representing the different cell types/states, in a grid shape of the size specified earlier.  For example, to load a grid filled with cell type/state 1, except for the corners (which I'll set to 0 for this example):
 -----
3
3
0 1 0
1 1 1
0 1 1
 -----
Simple enough, no?  The only tricky bit is knowing which number represents what cell type/state.  This can be found easily enough by opening the rule set the grid is designed to work for.  The cell types are numbered, starting at 0, from the top of the file down.  So a 1 will be the second cell in the rules file.

 :The .BMP Method:
A .bmp grid file might be a little trickier to figure out at first, but they're far simpler to edit.  When the program loads a .bmp grid file, it looks for colors in the file that match the colors of the cells defined in the rules file.  The colors have to be exact though, so make sure to find the RGB value in the rules file, (in the cell definitions, in the color tag of the cell, as <r>, <g> and <b>) and use the same values in the color you use in whatever image editing software you use. Alternatively, load the rule-set you want to make a grid for, use the mouse to add one of each tile, save it (press [s]), and then use the dropper tool to get the correct colors.
