Difference between revisions of "Template:PatternDownload"

From LifeWiki
Jump to navigation Jump to search
m
 
(127 intermediate revisions by 9 users not shown)
Line 1: Line 1:
<includeonly>{{#if: {{{rulemax|}}}{{{rulespecial|}}} | {{!}}-
<includeonly>{{#if:{{{rulespecial|}}}|[[Category:Pages needing cleanup]]|}}<!--
{{!}} colspan="2" style="height:3px;" {{!}}
-->{{#if: {{{rulemin|}}}{{{rulemax|}}} | <tr>
{{!}}-
{{!}} colspan="2" style="background-color:#A7A8C1;height:2px;" {{!}}
{{!}}-
{{!}} colspan="2" {{!}}
{{{!}} class="infobox_table collapsible collapsed" style="width:100%"
{{!}}-
! colspan="2" class="infobox_subhead" {{!}} [[Life-like cellular automaton|Rules]]
{{!}}-
! All&nbsp;rules
{{!}} style="text-align:right;" {{!}} {{#ifeq: {{{rulemin|}}} | {{{rulemax|}}} | {{{rulemax|}}} only | {{{rulemin|}}}&nbsp;–&nbsp;{{{rulemax|}}}}}
{{#if: {{{rulespecial|}}} | {{!}}-
! Important&nbsp;rules
{{!}} style="text-align:right;" valign="top" {{!}} {{{rulespecial|}}}
{{!}}- | {{!}}- }}
! #&nbsp;of&nbsp;rules
{{!}} style="text-align:right;" {{!}} 2<sup>{{#expr:{{#len:{{{rulemax|}}}}}-{{#len:{{{rulemin|}}}}}}}</sup> = {{#expr: 2^({{#len:{{{rulemax|}}}}}-{{#len:{{{rulemin|}}}}})}}
{{!}}}
}} {{#if: {{{synthesis|}}}{{{synthesisRLE|}}} | <tr>
<td colspan="2" style="height:3px;"></td></tr>
<td colspan="2" style="height:3px;"></td></tr>
<tr>
<tr>
Line 24: Line 6:
<tr>
<tr>
<td colspan="2">
<td colspan="2">
{{{!}} class="infobox_table collapsible collapsed" style="width:100%"
<table class="infobox_table collapsible collapsed" style="width:100%">
{{!}}-
<tr>
! colspan="2" class="infobox_subhead" {{!}} [[Glider synthesis]]
<th colspan="2" class="infobox_subhead">[[Life-like cellular automaton|Rules]]</th></tr>
{{#ifeq: {{{synthesis|}}} | 0 | {{!}}-
<tr>
{{!}} colspan="2" style="text-align:center;" {{!}} Synthesis is [[:Category:Patterns that can not be constructed with gliders|not possible]]. | {{!}}-
<th> [[Outer-totalistic]]&nbsp;rules </th>
{{#if: {{{synthesis|}}} | {{!}}-
<td style="text-align:right;"> {{#ifeq: {{{rulemin|}}} | {{{rulemax|}}} | {{{rulemax|}}} only | {{#if:{{{rulemin|}}}|{{{rulemin}}}|unknown}}&nbsp;–&nbsp;{{#if:{{{rulemax|}}}|{{{rulemax}}}|unknown}}}}</td></tr>
! Fewest&nbsp;[[glider]]s
<tr>
{{!}} style="text-align:right;" {{!}} [[:Category:Patterns that can be constructed with {{{synthesis|}}} gliders|{{{synthesis|}}}]]
<th> #&nbsp;of&nbsp;rules </th>
}}
<td style="text-align:right;"> {{#if: {{{rulemin|}}} | {{#if: {{{rulemax|}}} | 2<sup>{{#expr:{{#len:{{{rulemax|}}}}}-{{#len:{{{rulemin|}}}}}}}</sup> = {{#expr: 2^({{#len:{{{rulemax|}}}}}-{{#len:{{{rulemin|}}}}})}} | Unknown }} | Unknown }} </td></tr>
{{#if: {{{synthesisRLE|}}} | {{!}}-
{{#if: {{{isorulemin|}}}{{{isorulemax|}}} | <tr>
! Java&nbsp;link
<th> [[Isotropic non-totalistic|Isotropic]]&nbsp;rules </th>
{{!}} style="text-align:right;" {{!}} [http://www.conwaylife.com?p={{{pname|name}}}_synth click here]
<td style="text-align:right;"> {{#ifeq: {{{isorulemin|}}} | {{{isorulemax|}}} | {{{isorulemax|}}} only | {{#if:{{{isorulemin|}}}|{{{isorulemin}}}|unknown}}&nbsp;–&nbsp;{{#if:{{{isorulemax|}}}|{{{isorulemax}}}|unknown}}}}</td></tr>
{{!}}-
}}</table>
! [[RLE]]
</td></tr>
{{!}} style="text-align:right;" {{!}} [http://www.conwaylife.com/pattern.asp?p={{{pname|name}}}_synth.rle {{{pname|name}}}_synth.rle]
}}{{#if: {{{synthesis|}}}{{{synthesis2|}}}{{{synthesisRLE|}}}{{{pentadecathlonid|}}} | <tr>
}} }}
<td colspan="2" style="height:3px;"></td></tr>
{{!}}}</td></tr> }}
<tr>
{{#if: {{{life105|}}}{{{life106|}}}{{{plaintext|}}}{{{rle|}}} | {{!}}-
<td colspan="2" style="background-color:#A7A8C1;height:2px;"></td></tr>
{{!}} colspan="2" style="height:3px;" {{!}}
<tr>
{{!}}-
<td colspan="2"><table class="infobox_table collapsible collapsed" style="width:100%"><tr><th colspan="2" class="infobox_subhead"> [[Glider synthesis]] </th></tr>
{{!}} colspan="2" style="background-color:#A7A8C1;height:2px;" {{!}}
{{#ifeq: {{{synthesis|}}} | 0 | <tr>
{{!}}-
<td colspan="2" style="text-align:center;"> Synthesis is [[:Category:Patterns that can not be constructed with gliders|not possible]].</td></tr> |
{{!}} colspan="2" {{!}}
{{#if: {{{synthesis|}}} | <tr>
{{{!}} class="infobox_table collapsible collapsed" style="width:100%"
<th> Fewest&nbsp;[[glider]]s {{#if: {{{synthesis2|}}}{{{apgcode2|}}} | (canonical)}} </th>
{{!}}-
<td style="text-align:right;"> [[:Category:Patterns that can be constructed with {{GlidersCategoryName|{{{synthesis|}}}}} gliders|{{{synthesis|}}}]]{{#ifexpr: 0{{{synthesis|0}}} > {{Reverse caber tosser/Lower bound}} | <sup>&dagger;</sup> | }} </td></tr>
! colspan="2" class="infobox_subhead" {{!}} Pattern files
}}{{#if: {{{apgcode|}}} | {{#if: {{{synthesis|}}} | <tr>
{{#if: {{{life105|}}} | {{!}}-
<th> [[Catagolue]]-generated [[RLE]] {{#if: {{{synthesis2|}}}{{{apgcode2|}}} | (canonical)}}</th>
! [[Life 1.05]]
<td style="text-align:right;"> [https://catagolue.hatsya.com/textsamples/{{{apgcode|apgcodenotfound}}}/b3s23/synthesis synthesis] </td></tr>
{{!}} style="text-align:right;" {{!}} [http://www.conwaylife.com/pattern.asp?p={{{pname|name}}}_105.lif {{{pname|name}}}_105.lif]
}}}}{{#if: {{{synthesis2|}}} | <tr>
}}
<th> Fewest&nbsp;[[glider]]s (cheapest&nbsp;variant) </th>
{{#if: {{{life106|}}} | {{!}}-
<td style="text-align:right;"> [[:Category:Patterns that can be constructed with {{GlidersCategoryName|{{{synthesis2|}}}}} gliders|{{{synthesis2|}}}]]{{#ifexpr: 0{{{synthesis2|0}}} > {{Reverse caber tosser/Lower bound}} | <sup>&dagger;</sup> | }} </td></tr>
! [[Life 1.06]]
}}{{#if: {{{apgcode2|}}} | <tr>
{{!}} style="text-align:right;" {{!}} [http://www.conwaylife.com/pattern.asp?p={{{pname|name}}}_106.lif {{{pname|name}}}_106.lif]
<th> [[Catagolue]]-generated [[RLE]] (cheapest&nbsp;variant) </th>
}}
<td style="text-align:right;"> [https://catagolue.hatsya.com/textsamples/{{{apgcode2|apgcodenotfound}}}/b3s23/synthesis synthesis] </td></tr>
{{#if: {{{plaintext|}}} | {{!}}-
}}{{#if: {{{synthesisRLE|}}} | <tr>
! [[Plaintext]]
<th> Uploaded synthesis [[RLE]] </th>
{{!}} style="text-align:right;" {{!}} [http://www.conwaylife.com/pattern.asp?p={{{pname|name}}}.cells {{{pname|name}}}.cells]
<td style="text-align:right;"> [https://www.conwaylife.com/patterns/{{{pname|namenotfound}}}_synth.rle {{{pname|namenotfound}}}_synth.rle] </td></tr>
}}
| {{#ifexist:RLE:{{{pname}}}_synth|<tr>
{{#if: {{{rle|}}} | {{!}}-
<th>[[RLE]]</th>
! [[RLE]]
<td style="text-align:right;"> [[RLE:{{{pname}}}_synth|raw RLE code]] [[Category:Pages with raw synthesis RLE code but no uploaded synthesis files]] </td></tr> }} }} }}
{{!}} style="text-align:right;" {{!}} [http://www.conwaylife.com/pattern.asp?p={{{pname|name}}}.rle {{{pname|name}}}.rle]
<!--{{#if: {{{apgcode|}}} | <tr>
<th> Auto-generated synthesis </th>
<td style="text-align:right; word-break: break-all"> [https://glidersynth.neocities.org/?{{{apgcode|}}} {{{apgcode|}}}]<br>[https://catagolue.hatsya.com/js/glidersynth.html?{{{apgcode|}}} {{{apgcode|}}}] (alt.)</td></tr>
}}-->
{{#if: {{{pentadecathlonid|}}} |
<tr>
<th> As source </th>
<td style="text-align:right;"> [http://pentadecathlon.com/objects/object-info.php?objid={{{pentadecathlonid|}}}&content=foundations {{{pentadecathlonid|}}}] </td></tr>
<tr>
<th> As result </th>
<td style="text-align:right;"> [http://pentadecathlon.com/objects/object-info.php?objid={{{pentadecathlonid|}}}&content=constructions {{{pentadecathlonid|}}}] </td></tr>
}}{{#ifexpr: 0{{{synthesis|0}}} > {{Reverse caber tosser/Lower bound}} or 0{{{synthesis2|0}}} > {{Reverse caber tosser/Lower bound}} | <tr>
<td colspan="2"><sup>&dagger;</sup>Can be constructed with {{Reverse caber tosser/Lower bound}} gliders using the [[reverse caber tosser]] [[universal constructor]].</td></tr>
}}</table></td></tr> }} {{#if: {{{zip|}}}{{{mc|}}}{{{plaintext|}}}{{{rle|}}}{{#ifexist:RLE:{{{pname}}}|true|}} |
<tr>
<td colspan="2" style="height:3px;"></td></tr>
<tr>
<td colspan="2" style="background-color:#A7A8C1;height:2px;"></td></tr>
<tr>
<td colspan="2">
<table class="infobox_table collapsible collapsed" style="width:100%">
<tr>
<th colspan="2" class="infobox_subhead"> Pattern files </th></tr>
{{#if: {{{mc|}}} | <tr>
<th>[[Macrocell]]</th>
<td style="text-align:right;"> [https://www.conwaylife.com/patterns/{{{pname|name}}}.mc {{{pname|name}}}.mc]</td></tr>
}} {{#if: {{{plaintext|}}} | <tr>
<th>[[Plaintext]]</th>
<td style="text-align:right;"> [https://www.conwaylife.com/patterns/{{{pname|name}}}.cells {{{pname|name}}}.cells]</td></tr>
}} {{#if: {{{rle|}}} | <tr>
<th>[[RLE]]</th>
<td style="text-align:right;"> [https://www.conwaylife.com/patterns/{{{pname|name}}}.rle {{{pname|name}}}.rle]</td></tr>
| {{#ifexist:RLE:{{{pname}}}|<tr>
<th>[[RLE]]</th>
<td style="text-align:right;"> [[RLE:{{{pname}}}|raw RLE code]]</td></tr>
{{#if: {{{zip|}}}{{{mc|}}}{{{life105|}}}{{{life106|}}}{{{plaintext|}}}||[[Category:Pages with raw RLE code but no uploaded pattern files]]}}}}
}} {{#if: {{{zip|}}} | <tr>
<th>Zip archive</th>
<td style="text-align:right;"> [https://www.conwaylife.com/patterns/{{{pname|name}}}.zip {{{pname|name}}}.zip]</td></tr>
}}</table>
}}
}}
{{!}}} }}{{#if: {{{synthesis|}}} | {{#ifeq: {{{synthesis|}}} | 0 | [[Category:Patterns that can not be constructed with gliders]] | [[Category:Patterns that can be constructed with {{{synthesis|}}} gliders]]}} }}
{{#ifeq:{{NAMESPACE}}|User||{{#ifeq:{{NAMESPACE}}|Template||
</includeonly>
{{#if: {{{synthesis|}}} | {{#ifeq: {{{synthesis|}}} | 0 | [[Category:Patterns that can not be constructed with gliders]] | [[Category:Patterns that can be constructed with {{GlidersCategoryName|{{{synthesis|}}}}} gliders]] }} }}{{#if: {{{synthesis2|}}} | {{#ifeq: {{{synthesis2|}}} | 0 | [[Category:Patterns that can not be constructed with gliders]] | [[Category:Patterns that can be constructed with {{GlidersCategoryName|{{{synthesis2|}}}}} gliders]] }} }}{{#if: {{{rulemin|}}} | {{#if: {{{rulemax|}}} | {{#ifeq: {{{rulemin}}} | {{{rulemax}}} | [[Category:Outer-totalistically endemic patterns]] }} | [[Category:Patterns with unknown or incomplete rule information]] }} | [[Category:Patterns with unknown or incomplete rule information]] }}{{#if: {{{isorulemin|}}} | {{#if: {{{isorulemax|}}} | {{#ifeq: {{{isorulemin}}} | {{{isorulemax}}} | [[Category:Isotropically endemic patterns]] }} | [[Category:Patterns with unknown or incomplete rule information]] }} | [[Category:Patterns with unknown or incomplete rule information]] }} }} }}</includeonly>
<noinclude>This template displays the "Rules", "Glider synthesis" and "Pattern files" boxes that appear on the right hand side of pattern pages. It should not be used on its own, but only within other pattern infobox template such as [[Template:Pattern]] and [[Template:Oscillator]]. All of its parameters are passed in from the corresponding parameters of the template that calls it.
<noinclude>This template displays the "Rules", "Glider synthesis" and "Pattern files" boxes that appear on the right hand side of pattern pages. It should not be used on its own, but only within other pattern infobox templates such as [[Template:Pattern]] and [[Template:Oscillator]]. All of its parameters are passed in from the corresponding parameters of the template that calls it.
</noinclude>
[[Category:Infobox subtemplates]]</noinclude>

Latest revision as of 06:35, 16 September 2023

This template displays the "Rules", "Glider synthesis" and "Pattern files" boxes that appear on the right hand side of pattern pages. It should not be used on its own, but only within other pattern infobox templates such as Template:Pattern and Template:Oscillator. All of its parameters are passed in from the corresponding parameters of the template that calls it.