Difference between revisions of "Template:sandbox"
(There's still some TBD's to be done. You can contact the author.) |
m |
||
| (12 intermediate revisions by 11 users not shown) | |||
| Line 1: | Line 1: | ||
| − | {{ | + | <includeonly><!-- |
| − | | | + | --><metadesc>Explain xkcd is a wiki dedicated to explaining the webcomic xkcd. Go figure.</metadesc><!-- |
| + | --><table class="{{{bodyclass|}}}" cellspacing="5" | ||
| + | style="background-color: #FFFFFF; border: 1px solid #AAAAAA; color: black; font-size: 88%; line-height: 1.5em; | ||
| + | margin: 0.5em 0 0.5em 1em; padding: 0.2em; text-align: center; width:98%; {{{bodystyle|}}}"><!-- | ||
| − | + | ### Navigation bar (previous, next...) ### | |
| − | |||
| − | |||
| − | + | --><tr><td><!-- | |
| − | + | --><ul style="text-align: center; margin-bottom: 10px;" class="no-link-underline"><!-- | |
| − | + | ### Create the prev button ### | |
| − | |||
| − | + | --><li style="background-color: #6E7B91; | |
| − | + | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray; | |
| + | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600; | ||
| + | margin: 0 4px; padding: 1.5px 0;"><!-- | ||
| + | -->[[{{#expr:{{{number}}} - 1}}|<span style="color: #FFFFFF; padding: 0 12px;">< Prev</span>]]<!-- | ||
| + | --></li><!-- | ||
| − | + | ### Create a centre button with comic number, date (if exists) and link ### | |
| − | |||
| − | + | --><li style="background-color: #6E7B91; | |
| − | | | + | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray; |
| + | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600; | ||
| + | margin: 0 4px; padding: 1.5px 0;" | ||
| + | class="plainlinks"><!-- | ||
| + | -->[http://www.xkcd.com/{{{number}}}/ <!-- | ||
| + | --><span style="color: #FFFFFF; padding: 0 12px;">Comic #{{{number}}} {{#if:{{{date|}}}|({{{date}}})}}</span>]<!-- | ||
| + | --></li><!-- | ||
| − | + | ### If there is an article for the comic following this one, create a "next" ### | |
| − | |||
| − | + | -->{{#ifexist:{{#expr:{{{number}}} + 1}}<!-- | |
| − | + | -->|<li style="background-color: #6E7B91; | |
| − | + | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray; | |
| − | {{ | + | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600; |
| − | + | margin: 0 4px; padding: 1.5px 0;"><!-- | |
| − | + | -->[[{{#expr:{{{number}}} + 1}}|<span style="color: #FFFFFF; padding: 0 12px;">Next ></span>]]<!-- | |
| − | : | + | --></li><!-- |
| − | : | + | -->|<li style="display: inline; font-size: 16px; margin: 0 4px; padding: 1.5px 12px;"><!-- |
| − | : | + | --> <!-- |
| − | : | + | --></li><!-- |
| − | : | + | -->}}<!-- |
| − | + | --></ul><!-- | |
| − | : | + | --></td></tr><!-- |
| − | : | ||
| − | : | ||
| − | : | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | + | ### Comic title ### | |
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | ''' | + | -->{{#if:{{{title|}}}|<tr><td style="font-size: 20px; padding-bottom:10px"><!-- |
| − | + | -->'''{{{title}}}'''<!-- | |
| + | --></td></tr>}}<!-- | ||
| − | + | ### Text before comic ### | |
| − | + | -->{{#if:{{{before|}}}|<tr><td style="padding-bottom:10px"><!-- | |
| − | + | -->{{{before}}}<!-- | |
| + | --></td></tr>}}<!-- | ||
| − | + | ### Comic image and title text ### | |
| − | + | --><tr><td><!-- | |
| + | -->{{#if: {{{custom|}}} |<!-- | ||
| + | -->{{{custom|}}}|<!-- | ||
| + | -->{{#if:{{{image|}}}|[[File:{{{image|}}}|{{{imagesize|}}}|{{{titletext|}}}]]}}}}<!-- | ||
| + | -->{{#if:{{{imagesize|}}}|<br />[Click comic to enlarge]}}<!-- | ||
| + | -->{{#if:{{{titletext|}}}|<br /><span style="{{{captionstyle|}}}"><span style="color:grey">Title text:</span> {{{titletext}}}</span>}}<!-- | ||
| + | --></td></tr><!-- | ||
| − | + | ### Transcript ### | |
| − | + | -->{{{transcript}}}<!-- | |
| + | -->{{#if: {{{transcript|}}} |<!-- | ||
| + | --><tr><td style="font-size: 50px; padding-bottom:3px; padding-top:10px">Transcript<!-- | ||
| + | --><div class="mw-collapsible mw-collapsed"><!-- | ||
| + | -->{{{transcript|}}}<!-- | ||
| + | --></div><!-- | ||
| + | --></td></tr>}}<!-- | ||
| − | + | --></table><!-- | |
| − | + | ### Add categories to comic based on date field ### | |
| − | + | -->{{DEFAULTSORT: {{padleft:{{{number}}}|4}}}}<!-- (default sorting key for all categories: use zero-padding to make sure #9 comes before #10, etc.) | |
| + | -->{{#ifeq:{{NAMESPACE}}|{{ns:0}}|<!-- (no categorization except for the main namespace) | ||
| + | -->{{#ifeq:{{FULLPAGENAME}}|{{int:mainpage}}||<!-- (no categorization when transcluded into the main page) | ||
| + | -->[[Category:Comics]]<!-- | ||
| + | -->{{#if:{{{date|}}}|<!-- | ||
| + | -->[[Category:Comics from {{#time:Y|{{{date}}}}}]]<!-- (categorize by year) | ||
| + | -->[[Category:Comics from {{#time:F|{{{date}}}}}]]<!-- (categorize by month) | ||
| + | -->[[Category:{{#time:l|{{{date}}}}} comics]]<!-- (categorize by weekday) | ||
| + | -->}}<!-- | ||
| + | -->}}<!-- | ||
| + | -->|}}<!-- | ||
| − | + | ### DOCUMENTATION ### | |
| − | + | --></includeonly><noinclude> | |
| − | + | This is the basic infobox-style header template used to display <span style="background:#0064de;font-size:12px;padding:4px 12px;border-radius:8px;">[[xkcd|<span style="color:#f0faff;">xkcd</span>]]</span> comics on their own pages, including the comic number (with external link to xkcd), publication date, title, comic image, and title text. | |
| − | + | == Sample == | |
| − | |||
| − | |||
| − | |||
| − | + | The following is a sample usage of this template: | |
| − | + | {{sandbox | |
| − | + | | number = 16 | |
| − | + | | date = October 4, 2005 | |
| − | + | | title = Monty Python -- Enough | |
| − | + | | image = monty_python.jpg | |
| − | + | | titletext = I went to a dinner where there was a full 10 minutes of Holy Grail quotes exchanged, with no context, in lieu of conversation. It depressed me badly. | |
| − | + | | transcript= I went to a dinner where there was a full 10 minutes of Holy Grail quotes exchanged, with no context, in lieu of conversation. It depressed me badly. | |
| − | + | }} | |
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | : | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | { | ||
| − | |||
| − | | | ||
| − | | | ||
| − | |- | ||
| − | |||
| − | |||
| − | | | ||
| − | | | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | + | == Usage == | |
| − | + | <pre>{{comic | |
| + | | number = | ||
| + | | date = | ||
| + | | title = | ||
| + | | before = | ||
| + | | image = | ||
| + | | custom = | ||
| + | | imagesize = | ||
| + | | titletext = | ||
| + | | transcript= | ||
| + | }}</pre> | ||
| − | + | === Notes === | |
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | ''' | + | * At least the number, title and image are required. |
| − | : '' | + | * The date should be written in the form: January 1, 2006 |
| + | * The imagesize field is optional. | ||
| + | ** The comic's '''width''' will be limited to the set size. Format must be in pixels (eg: "350px") | ||
| + | ** The comic's '''height''' may be set by adding an 'x' to the start (eg: "x350px") | ||
| + | ** Warning: If the size is larger than the image, the image will be stretched. | ||
| + | * '''before''' is a special field for inserting text before the comic. One use is for extremely large comics (e.g. [[Umwelt]]), to skip to the explanation. | ||
| + | * If the '''custom''' field is not empty, the image field will be ignored and be replaced with any text that you put in the '''custom''' field. | ||
| − | + | The above sample is produced by the following code: [http://www.bilibili.com/video/BV1px4y1x75n/ tvtropes] | |
| − | + | <pre>{{comic | |
| − | + | | number = 16 | |
| − | + | | date = October 4, 2005 | |
| + | | title = Monty Python -- Enough | ||
| + | | image = monty_python.jpg | ||
| + | | titletext = I went to a dinner where there was a full 10 minutes of Holy Grail quotes exchanged, with no context, in lieu of conversation. It depressed me badly. | ||
| + | }}</pre> | ||
| − | + | <div class="mw-collapsible mw-collapsed"> | |
| + | ;B-Univ<br> | ||
| + | <pre>@RULE B-Univ | ||
| + | #State 1 is wire | ||
| + | #State 2 is turn right signal/command | ||
| + | #State 3 is signal tail, also emulates B2ae/S | ||
| + | #State 4 is turn left signal/command | ||
| + | #State 5 is the hand | ||
| + | #State 6 is retract signal/command | ||
| + | #State 7 is extend signal/command | ||
| + | @TABLE | ||
| + | n_states:8 | ||
| + | neighborhood:Moore | ||
| + | symmetries:rotate4 | ||
| + | var s = {2,4,6,7} | ||
| + | var s1 = {2,4,6,7} | ||
| + | var s2 = {4,6,7} | ||
| + | var s3 = {2,6,7} | ||
| + | var s4 = {2,4,7} | ||
| + | var s5 = {2,4,6} | ||
| + | var ts = {2,4} | ||
| + | var a1 = {0,1,2,3,4,5,6,7} | ||
| + | var a2 = {0,1,2,3,4,5,6,7} | ||
| + | var a3 = {0,1,2,3,4,5,6,7} | ||
| + | var a4 = {0,1,2,3,4,5,6,7} | ||
| + | var a5 = {0,1,2,3,4,5,6,7} | ||
| + | var a6 = {0,1,2,3,4,5,6,7} | ||
| + | var a7 = {0,1,2,3,4,5,6,7} | ||
| + | var a8 = {0,1,2,3,4,5,6,7} | ||
| + | var w1 = {0,1,3,5} | ||
| + | var w2 = {0,1,3,5} | ||
| + | var w3 = {0,1,3,5} | ||
| + | var w4 = {0,1,3,5} | ||
| + | var w5 = {0,1,3,5} | ||
| + | var w6 = {0,1,3,5} | ||
| + | var w7 = {0,1,3,5} | ||
| + | var w8 = {0,1,3,5} | ||
| + | var b1 = {0,5} | ||
| + | var b2 = {0,5} | ||
| + | var b3 = {0,5} | ||
| + | var b4 = {0,5} | ||
| + | var b5 = {0,5} | ||
| + | var b6 = {0,5} | ||
| + | var b7 = {0,5} | ||
| + | var l1 = {0,3} | ||
| + | var l2 = {0,3} | ||
| + | var l3 = {0,3} | ||
| + | var l4 = {0,3} | ||
| + | var l5 = {0,3} | ||
| + | var l6 = {0,3} | ||
| + | var l7 = {0,3} | ||
| + | var l8 = {0,3} | ||
| + | var h = {1,5} | ||
| + | 0,1,0,1,0,0,0,0,0,1 | ||
| + | 0,5,1,w1,w2,a1,a2,a3,6,5 | ||
| + | 0,5,4,a1,a2,a3,a4,a5,a6,5 | ||
| + | 0,5,0,0,0,a1,1,1,2,0 | ||
| + | 0,5,0,a1,a2,a3,a4,a5,2,5 | ||
| + | 0,1,3,2,5,0,0,0,0,0 | ||
| + | 0,a1,2,5,a2,a3,a4,a5,0,5 | ||
| + | 0,5,1,a1,a2,a3,a4,a5,6,5 | ||
| + | 0,6,5,0,0,0,0,0,5,1 | ||
| + | 0,6,5,w1,w2,w3,w4,w5,5,3 | ||
| + | 0,3,0,3,0,0,0,0,0,3 | ||
| + | 0,3,3,0,0,0,0,0,0,3 | ||
| + | 0,0,3,3,0,0,0,0,0,3 | ||
| + | 0,0,3,6,5,5,0,0,0,6 | ||
| + | s,3,0,5,1,1,1,5,0,0 | ||
| + |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4,a5,w6,w7,s | ||
| + | 3,1,a1,a2,5,6,5,a3,a4,5 | ||
| + | 6,s4,w1,w2,w3,3,w4,w5,w6,1 | ||
| + | 6,3,0,5,a1,1,a2,5,0,1 | ||
| + | 6,3,w1,w2,w3,5,w4,w5,w6,5 | ||
| + | 7,5,a1,a2,a3,a4,a5,a6,a7,3 | ||
| + | s,1,a1,a2,a3,a4,a5,a6,a7,3 | ||
| + | 3,a1,a2,a3,a4,a5,a6,a7,a8,1 | ||
| + | 5,7,a1,a2,a3,a4,a5,a6,a7,7 | ||
| + | 5,6,a1,a2,a3,a4,a5,a6,a7,0 | ||
| + | 0,7,0,a1,a2,a3,a4,a5,0,5 | ||
| + | 6,0,a1,a2,a3,a4,a5,a6,a7,0 | ||
| + | s,0,a1,a2,a3,a4,a5,a6,a7,1 | ||
| + | @NAMES | ||
| + | 0 dead | ||
| + | 1 wire | ||
| + | 2 RIGHT command | ||
| + | 3 signal tail | ||
| + | 4 LEFT command | ||
| + | 5 hand | ||
| + | 6 RETRACT command | ||
| + | 7 EXTEND command | ||
| + | @COLORS | ||
| + | 1 0 0 255 | ||
| + | 2 0 255 0 | ||
| + | 3 255 0 0 | ||
| + | 4 255 255 0 | ||
| + | 5 255 0 255 | ||
| + | 6 255 255 255 | ||
| + | 7 0 255 255</pre> | ||
| + | ;B+Univ<br> | ||
| + | <pre>@RULE B+Univ | ||
| + | @TABLE | ||
| + | n_states:8 | ||
| + | neighborhood:Moore | ||
| + | symmetries:rotate4reflect | ||
| + | # v1.1.0 - Integrated the newest stable CataProp release | ||
| + | var w={0,1} # Empty and blue | ||
| + | var w1=w | ||
| + | var w2=w | ||
| + | var a={0,1,2,3,4,5,6,7} # All cells | ||
| + | var a1=a | ||
| + | var a2=a | ||
| + | var a3=a | ||
| + | var a4=a | ||
| + | var a5=a | ||
| + | var a6=a | ||
| + | var a7=a | ||
| + | var c={0,3,5} # CataProp cells | ||
| + | var c5=c | ||
| + | var c3=c | ||
| + | var c3=c | ||
| + | var c4=c | ||
| + | var c5=c | ||
| + | var c6=c | ||
| + | var c7=c | ||
| + | var d={0,1,2,4,5,6,7} # All cells except red | ||
| + | var s={2,4,6,7} # Signal heads | ||
| − | + | 0,s,1,5,1,0,1,5,1,7 # Color changer | |
| + | 0,7,1,5,5,0,5,5,1,4 | ||
| + | 0,4,1,5,5,0,5,5,1,2 | ||
| + | 0,2,1,5,5,0,5,5,1,6 | ||
| − | + | 5,0,5,0,5,0,0,0,0,3 # T-ship | |
| + | 0,5,0,0,0,3,0,0,0,5 | ||
| + | 0,3,0,0,5,5,5,0,0,3 | ||
| + | 0,5,0,5,0,5,0,0,0,3 | ||
| + | 0,0,5,3,5,0,0,0,c,3 | ||
| + | 0,0,5,3,5,0,5,3,5,3 | ||
| + | 0,5,3,5,5,0,0,0,0,5 | ||
| + | 0,5,5,5,0,0,0,0,0,5 | ||
| + | 5,5,0,5,5,0,0,0,0,3 | ||
| + | 5,0,3,3,3,0,0,0,0,0 | ||
| + | 5,5,3,0,0,5,0,0,0,0 | ||
| + | 5,0,3,5,0,5,5,5,0,0 | ||
| + | 5,0,5,5,0,5,0,5,5,0 | ||
| + | 3,0,5,3,5,0,5,3,5,3 | ||
| + | 3,0,5,3,5,0,c,0,0,3 | ||
| + | 3,5,c,0,0,5,0,0,0,3 | ||
| + | 0,3,3,5,c3,c,c5,c3,0,5 | ||
| + | 5,3,3,0,c,c5,c3,0,0,0 | ||
| + | 3,c,c5,c3,c3,c4,c5,c6,c7,0 # Red otherwise dies | ||
| − | + | 0,2,5,0,0,0,0,0,0,1 # Make FIRE elbow | |
| − | + | 1,s,5,0,a,a1,a2,a3,a4,0 # Delete blue after FIRE | |
| + | 0,0,5,4,3,0,0,0,0,5 # Switch magenta | ||
| + | 0,5,5,7,3,0,0,0,0,7 # Make new elbow usable | ||
| + | 5,1,0,0,6,5,a,a1,a2,5 | ||
| + | 5,4,5,0,0,0,0,0,a,0 # Kill magenta after switch | ||
| + | 0,0,3,2,5,0,0,0,0,3 # Make new hand | ||
| + | 0,4,5,0,0,0,0,0,0,5 # Make DO elbow | ||
| + | 0,0,3,s,5,0,a,a1,a2,s # Signal make turn on elbow | ||
| + | 0,5,a,0,6,0,a1,a2,a3,5 # Pull magenta | ||
| + | 5,0,5,7,3,a,a1,a2,a3,5 # Keep magenta after making abnew magenta | ||
| + | 5,7,5,d,a1,a2,a3,a4,a5,0 # Kill magenta after creating one using cyan | ||
| + | 5,5,6,3,0,0,a,a1,a2,0 # Kill magenta in FIRE elbow | ||
| + | 0,6,5,5,0,1,a,a1,a2,6 # Keep white in FIRE elbow | ||
| + | 0,6,5,5,0,a,a1,a2,a3,0 # Kill white after pulling | ||
| + | 5,5,0,0,6,5,a,a1,a2,5 # Keep magenta if there's a cell next to to it | ||
| + | 5,5,6,0,1,a,a1,a2,a3,5 # Keep magenta in FIRE elbow | ||
| + | 5,5,6,0,a,a1,a2,a3,a4,0 # Kill magenta | ||
| + | 0,7,5,0,0,0,0,0,0,3 # Push action from Sticky | ||
| + | 0,3,3,5,a3,a,a1,a2,0,5 # Add magenta | ||
| + | 5,3,3,0,a,a1,a2,0,0,0 # Kill magenta | ||
| + | 0,s,d,a,a1,a2,a3,a4,d,s # Signal propagation | ||
| + | 0,s,3,a,a1,a2,a3,a4,1,s # Signal splits | ||
| + | 0,s,3,1,a,a1,a2,1,a3,s # Signal splits | ||
| + | s,a,a1,a2,a3,a4,a5,a6,a7,3 # Red always decay from head | ||
| + | 3,a,a1,a2,a3,a4,a5,a6,a7,0 # Red always die | ||
| + | @NAMES | ||
| + | 0 Empty | ||
| + | 1 Sheath | ||
| + | 2 FIRE/MKARM | ||
| + | 3 Signal tail | ||
| + | 4 DO/SWITCH | ||
| + | 5 Hand/elbow | ||
| + | 6 PULL/CLEAR | ||
| + | 7 PUSH/ADD | ||
| + | @COLORS | ||
| + | 1 0 0 255 | ||
| + | 2 0 255 0 | ||
| + | 3 255 0 0 | ||
| + | 4 255 255 0 | ||
| + | 5 255 0 255 | ||
| + | 6 255 255 255 | ||
| + | 7 0 255 255</pre> | ||
| + | </div> | ||
| − | |||
| − | |||
| − | : | + | [[Category:Templates]] |
| + | </noinclude> | ||
Latest revision as of 03:37, 5 November 2024
This is the basic infobox-style header template used to display xkcd comics on their own pages, including the comic number (with external link to xkcd), publication date, title, comic image, and title text.
Sample[edit]
The following is a sample usage of this template:
Usage[edit]
{{comic
| number =
| date =
| title =
| before =
| image =
| custom =
| imagesize =
| titletext =
| transcript=
}}
Notes[edit]
- At least the number, title and image are required.
- The date should be written in the form: January 1, 2006
- The imagesize field is optional.
- The comic's width will be limited to the set size. Format must be in pixels (eg: "350px")
- The comic's height may be set by adding an 'x' to the start (eg: "x350px")
- Warning: If the size is larger than the image, the image will be stretched.
- before is a special field for inserting text before the comic. One use is for extremely large comics (e.g. Umwelt), to skip to the explanation.
- If the custom field is not empty, the image field will be ignored and be replaced with any text that you put in the custom field.
The above sample is produced by the following code: tvtropes
{{comic
| number = 16
| date = October 4, 2005
| title = Monty Python -- Enough
| image = monty_python.jpg
| titletext = I went to a dinner where there was a full 10 minutes of Holy Grail quotes exchanged, with no context, in lieu of conversation. It depressed me badly.
}}
- B-Univ
@RULE B-Univ
#State 1 is wire
#State 2 is turn right signal/command
#State 3 is signal tail, also emulates B2ae/S
#State 4 is turn left signal/command
#State 5 is the hand
#State 6 is retract signal/command
#State 7 is extend signal/command
@TABLE
n_states:8
neighborhood:Moore
symmetries:rotate4
var s = {2,4,6,7}
var s1 = {2,4,6,7}
var s2 = {4,6,7}
var s3 = {2,6,7}
var s4 = {2,4,7}
var s5 = {2,4,6}
var ts = {2,4}
var a1 = {0,1,2,3,4,5,6,7}
var a2 = {0,1,2,3,4,5,6,7}
var a3 = {0,1,2,3,4,5,6,7}
var a4 = {0,1,2,3,4,5,6,7}
var a5 = {0,1,2,3,4,5,6,7}
var a6 = {0,1,2,3,4,5,6,7}
var a7 = {0,1,2,3,4,5,6,7}
var a8 = {0,1,2,3,4,5,6,7}
var w1 = {0,1,3,5}
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,5,b1,b2,b3,b4,b5,b6,b7,0
5,b1,5,b2,b3,b4,b5,b6,b7,0
5,ts,0,5,a1,0,a2,0,0,1
5,ts,0,0,a1,0,a2,5,0,1
5,5,s,w1,w2,w3,w4,w5,w6,5
1,0,5,s,0,0,0,w1,0,1
1,s,0,0,0,0,0,5,0,s
1,s,0,0,0,w1,0,5,0,1
1,0,5,5,5,0,a1,0,a3,5
1,0,1,1,0,3,0,1,1,0
1,5,1,s,3,0,0,0,0,1
1,s,1,5,a1,1,0,0,0,7
1,7,5,5,a1,1,0,0,0,2
1,2,5,5,a1,1,0,0,0,4
1,4,5,5,a1,1,0,0,0,6
1,s,w1,w2,a3,w4,a5,w6,w7,s
3,1,a1,a2,5,6,5,a3,a4,5
6,s4,w1,w2,w3,3,w4,w5,w6,1
6,3,0,5,a1,1,a2,5,0,1
6,3,w1,w2,w3,5,w4,w5,w6,5
7,5,a1,a2,a3,a4,a5,a6,a7,3
s,1,a1,a2,a3,a4,a5,a6,a7,3
3,a1,a2,a3,a4,a5,a6,a7,a8,1
5,7,a1,a2,a3,a4,a5,a6,a7,7
5,6,a1,a2,a3,a4,a5,a6,a7,0
0,7,0,a1,a2,a3,a4,a5,0,5
6,0,a1,a2,a3,a4,a5,a6,a7,0
s,0,a1,a2,a3,a4,a5,a6,a7,1
@NAMES
0 dead
1 wire
2 RIGHT command
3 signal tail
4 LEFT command
5 hand
6 RETRACT command
7 EXTEND command
@COLORS
1 0 0 255
2 0 255 0
3 255 0 0
4 255 255 0
5 255 0 255
6 255 255 255
7 0 255 255
- B+Univ
@RULE B+Univ
@TABLE
n_states:8
neighborhood:Moore
symmetries:rotate4reflect
# v1.1.0 - Integrated the newest stable CataProp release
var w={0,1} # Empty and blue
var w1=w
var w2=w
var a={0,1,2,3,4,5,6,7} # All cells
var a1=a
var a2=a
var a3=a
var a4=a
var a5=a
var a6=a
var a7=a
var c={0,3,5} # CataProp cells
var c5=c
var c3=c
var c3=c
var c4=c
var c5=c
var c6=c
var c7=c
var d={0,1,2,4,5,6,7} # All cells except red
var s={2,4,6,7} # Signal heads
0,s,1,5,1,0,1,5,1,7 # Color changer
0,7,1,5,5,0,5,5,1,4
0,4,1,5,5,0,5,5,1,2
0,2,1,5,5,0,5,5,1,6
5,0,5,0,5,0,0,0,0,3 # T-ship
0,5,0,0,0,3,0,0,0,5
0,3,0,0,5,5,5,0,0,3
0,5,0,5,0,5,0,0,0,3
0,0,5,3,5,0,0,0,c,3
0,0,5,3,5,0,5,3,5,3
0,5,3,5,5,0,0,0,0,5
0,5,5,5,0,0,0,0,0,5
5,5,0,5,5,0,0,0,0,3
5,0,3,3,3,0,0,0,0,0
5,5,3,0,0,5,0,0,0,0
5,0,3,5,0,5,5,5,0,0
5,0,5,5,0,5,0,5,5,0
3,0,5,3,5,0,5,3,5,3
3,0,5,3,5,0,c,0,0,3
3,5,c,0,0,5,0,0,0,3
0,3,3,5,c3,c,c5,c3,0,5
5,3,3,0,c,c5,c3,0,0,0
3,c,c5,c3,c3,c4,c5,c6,c7,0 # Red otherwise dies
0,2,5,0,0,0,0,0,0,1 # Make FIRE elbow
1,s,5,0,a,a1,a2,a3,a4,0 # Delete blue after FIRE
0,0,5,4,3,0,0,0,0,5 # Switch magenta
0,5,5,7,3,0,0,0,0,7 # Make new elbow usable
5,1,0,0,6,5,a,a1,a2,5
5,4,5,0,0,0,0,0,a,0 # Kill magenta after switch
0,0,3,2,5,0,0,0,0,3 # Make new hand
0,4,5,0,0,0,0,0,0,5 # Make DO elbow
0,0,3,s,5,0,a,a1,a2,s # Signal make turn on elbow
0,5,a,0,6,0,a1,a2,a3,5 # Pull magenta
5,0,5,7,3,a,a1,a2,a3,5 # Keep magenta after making abnew magenta
5,7,5,d,a1,a2,a3,a4,a5,0 # Kill magenta after creating one using cyan
5,5,6,3,0,0,a,a1,a2,0 # Kill magenta in FIRE elbow
0,6,5,5,0,1,a,a1,a2,6 # Keep white in FIRE elbow
0,6,5,5,0,a,a1,a2,a3,0 # Kill white after pulling
5,5,0,0,6,5,a,a1,a2,5 # Keep magenta if there's a cell next to to it
5,5,6,0,1,a,a1,a2,a3,5 # Keep magenta in FIRE elbow
5,5,6,0,a,a1,a2,a3,a4,0 # Kill magenta
0,7,5,0,0,0,0,0,0,3 # Push action from Sticky
0,3,3,5,a3,a,a1,a2,0,5 # Add magenta
5,3,3,0,a,a1,a2,0,0,0 # Kill magenta
0,s,d,a,a1,a2,a3,a4,d,s # Signal propagation
0,s,3,a,a1,a2,a3,a4,1,s # Signal splits
0,s,3,1,a,a1,a2,1,a3,s # Signal splits
s,a,a1,a2,a3,a4,a5,a6,a7,3 # Red always decay from head
3,a,a1,a2,a3,a4,a5,a6,a7,0 # Red always die
@NAMES
0 Empty
1 Sheath
2 FIRE/MKARM
3 Signal tail
4 DO/SWITCH
5 Hand/elbow
6 PULL/CLEAR
7 PUSH/ADD
@COLORS
1 0 0 255
2 0 255 0
3 255 0 0
4 255 255 0
5 255 0 255
6 255 255 255
7 0 255 255

