I'm trying to create a rule that combines wires (like in wireworld, Langton loops and JvN) and photons moving in the void (like in Blocks and Walls).
So far, these are the states:
0 : void
1 : void-photon's head
2 : void-photon's tail
3 : wire
4 : wire-photon's head
5 : wire-photon's tail
6 : void/wire extender
Code: Select all
n_states:8
neighborhood:Moore
symmetries:rotate4
var a1 = {0,1,2,3,4,5,6,7}
var a2 = a1
var a3 = a1
var a4 = a1
var a5 = a1
var a6 = a1
var a7 = a1
var a8 = a1
var btw1 = {0,1,4}
var btw2 = btw1
var head = {1,4}
var tail = {2,5}
var pass = {0,3}
# 8 1 2
# 7 C 3
# 6 5 4
#> Void-Photon Fusion
0,0,2,1,1,2,0,0,0,2
0,0,0,0,0,0,1,1,2,1
0,0,0,0,0,0,2,1,1,1
#> Photon Collisions
1,2,a2,a3,a4,2,a6,a7,a8,2
#> Photon Logic Transitions
#>> Void/Wire Extender
0,0,0,0,0,0,6,4,a8,3 #Extend Wire
0,0,0,0,0,0,a8,4,6,3 #Extend Wire (reflect)
0,tail,head,6,a4,a5,a6,a7,a8,0 #BUGFIXER !
0,a1,a2,6,head,tail,a6,a7,a8,0 #BUGFIXER !
0,a1,a2,a3,a4,a5,a6,6,head,6 #Advance Extender
6,head,a2,a3,a4,a5,a6,a7,tail,0 #Clear Extender
0,a1,head,6,a4,a5,a6,a7,a8,6 #Advance Extender (reflect)
6,a1,a2,a3,a4,head,tail,a7,a8,0 #Clear Extender (reflect)
#> Void Reflection Wall
2,0,0,0,0,0,6,6,6,1
6,6,0,2,0,6,0,0,0,2
0,0,0,6,2,0,0,0,0,6 #Make the new wall
0,0,6,2,6,0,0,0,0,6 # ^ ^ ^ ^
0,0,2,6,0,0,0,0,0,6 # ^ ^ ^ ^
6,0,0,0,1,2,0,0,0,0 #Destroy old wall
6,2,1,0,0,0,0,0,0,0 # ^ ^ ^ ^
#> General Photon transition
1,a1,a2,a3,a4,a5,a6,a7,a8,2 #Head to Tail
4,a1,a2,a3,a4,a5,a6,a7,a8,5 #^^
2,a1,a2,a3,a4,a5,a6,a7,a8,0 #Tail to Void
5,a1,a2,a3,a4,a5,a6,a7,a8,3 #Tail to Wire
0,a1,a2,a3,btw1,head,btw2,a7,a8,1 #Void to Head
3,a1,a2,a3,btw1,head,btw2,a7,a8,4 #Wire to Head
0,a1,a2,a3,3,1,btw1,a7,a8,1 #BUGFIXER !
0,a1,a2,a3,btw1,1,3,a7,a8,1 #BUGFIXER !
0,a1,a2,a3,3,1,3,a7,a8,1 #Can pass wire gates
#> Wire Corners
3,a1,a2,a3,a4,4,a6,a7,a8,4
Code: Select all
color=1 128 128 128
color=2 230 230 230
color=3 216 100 000
color=4 013 120 075
color=5 205 230 230
color=6 255 166 077