git @ Cat's Eye Technologies Jaccia / dc7878c
Use neighbourhood feature of ALPACA 1.0 to shorten descriptions. catseye 7 years ago
2 changed file(s) with 17 addition(s) and 34 deletion(s). Raw diff Collapse all Expand all
00 /*
1 * The Jaccia automaton, expressed in ALPACA.
1 * The Jaccia automaton, expressed in ALPACA 1.0.
22 * Inspired by the Scientific Announcement that
33 * Slime Molds are Intelligent Maze-Solvers.
44 * April 11 2009, Chris Pressey, Cat's Eye Technologies.
5 * Updated to ALPACA 1.0 on March 20, 2013.
56 */
7
8 neighbourhood VonNeumann
9 (^ v < >);
610
711 class Sustainer;
812
1418 is Sustainer;
1519 state Slime "%"
1620 is Sustainer
17 to Space when not ((^ is Sustainer and > is Sustainer) or
18 (^ is Sustainer and v is Sustainer) or
19 (^ is Sustainer and < is Sustainer) or
20 (> is Sustainer and v is Sustainer) or
21 (> is Sustainer and < is Sustainer) or
22 (v is Sustainer and < is Sustainer)).
21 to Space when not 2 in VonNeumann is Sustainer.
11 * The Jacciata automaton, expressed in ALPACA.
22 * Inspired by Jaccia.
33 * April 11 2009, Chris Pressey, Cat's Eye Technologies.
4 * Updated to ALPACA 1.0 on March 20, 2013.
45 */
6
7 neighbourhood VonNeumann
8 (^ v < >);
59
610 class Starter;
711 class Sustainer;
1822 */
1923 state Slime "%"
2024 is Sustainer
21 to Space when not ((^ is Sustainer and > is Sustainer) or
22 (^ is Sustainer and v is Sustainer) or
23 (^ is Sustainer and < is Sustainer) or
24 (> is Sustainer and v is Sustainer) or
25 (> is Sustainer and < is Sustainer) or
26 (v is Sustainer and < is Sustainer))
27 or /* this part lets conflicts be resolved */
28 ((^ Head and > Head) or
29 (^ Head and v Head) or
30 (^ Head and < Head) or
31 (> Head and v Head) or
32 (> Head and < Head) or
33 (v Head and < Head)),
34 to Head when (v is Starter or ^ is Starter or > is Starter or < is Starter);
25 to Space when (not 2 in VonNeumann is Sustainer)
26 /* this part lets conflicts be resolved */
27 or 2 in VonNeumann Head,
28 to Head when 1 in VonNeumann is Starter;
3529
3630 state Head "-"
3731 is Starter
4842 state Body "?"
4943 is Starter
5044 is Sassy
51 to Solved when (v is Solution or ^ is Solution or > is Solution or < is Solution),
52 to Space when not ((^ is Sassy and > is Sassy) or
53 (^ is Sassy and v is Sassy) or
54 (^ is Sassy and < is Sassy) or
55 (> is Sassy and v is Sassy) or
56 (> is Sassy and < is Sassy) or
57 (v is Sassy and < is Sassy));
45 to Solved when 1 in VonNeumann is Solution,
46 to Space when not 2 in VonNeumann is Sassy;
5847
5948 /*
6049 * Solved cells survive on the same rules as body cells.
6251 state Solved "@"
6352 is Sassy
6453 is Solution
65 to Space when not ((^ is Sassy and > is Sassy) or
66 (^ is Sassy and v is Sassy) or
67 (^ is Sassy and < is Sassy) or
68 (> is Sassy and v is Sassy) or
69 (> is Sassy and < is Sassy) or
70 (v is Sassy and < is Sassy));
54 to Space when not 2 in VonNeumann is Sassy;
7155
7256 state Start "S"
7357 is Starter