Difference between revisions of "ScanCategory"

From Sega Retro

 
(7 intermediate revisions by the same user not shown)
Line 3: Line 3:
 
{{#vardefine:type|{{#explode:{{#var:name}}| |{{#expr:{{#var:wordcount}}-1}}}}}}
 
{{#vardefine:type|{{#explode:{{#var:name}}| |{{#expr:{{#var:wordcount}}-1}}}}}}
 
{{#vardefine:region|{{#explode:{{#var:name}}| |{{#expr:{{#var:wordcount}}-2}}}}}}
 
{{#vardefine:region|{{#explode:{{#var:name}}| |{{#expr:{{#var:wordcount}}-2}}}}}}
{{#vardefine:format|{{#replace:{{#replace:{{#replace:{{#var:name}}|{{#var:region}}|}}|{{#var:type}}}}|scans|}}}}</div>
+
{{#switch:{{#var:region}}
{{#switch:{{lc:{{#var:region}}}}
+
|console
|as|ex=
+
|accessory
|bx={{float|{{flag|BE|100}}  {{flag|NL|100}} {{flag|LU|100}}}}
+
|bootleg
|#default={{float|{{flag|{{#var:region}}|200}}}}
+
|multi-cart={{#vardefine:region|{{#explode:{{#var:name}}| |{{#expr:{{#var:wordcount}}-3}}}}}}{{#vardefine:extracat|true}}
 
}}
 
}}
[[{{#var:format}}]] {{#var:type}} scans from {{CountrySentence|{{CountryCode2Country|{{#var:region}}}}}}.{{#ifeq:{{NAMESPACE}}|Category|[[Category:{{#var:format}} {{#var:type}} scans]][[Category:All {{#var:region}} scans]]}}</includeonly><noinclude>
+
{{#vardefine:format|{{#replace:{{#replace:{{#replace:{{#var:name}}|{{#var:region}}|}}|{{#var:type}}}}|scans|}}}}
 +
{{#if:{{#var:extracat}}|{{#vardefine:format2|{{#replace:{{#replace:{{#replace:{{#replace:{{#var:format}}|console|}}|accessory|}}|bootleg|}}|multi-cart|}}}}|}}
 +
{{#ifeq:{{#pos:{{#var:format}}|X<nowiki> </nowiki>}}|0|{{#vardefine:format|Xbox{{#sub:{{#var:format}}|1}}}}|}}{{#vardefine:format|{{#replace:{{#var:format}}|Xboxbox|Xbox}}}}<!--lazy Xbox fix--></div>
 +
{{CategoryFlag|{{#var:region}}}}
 +
Scans of [[{{#var:format}}]] {{#switch:{{#var:type}}|box=boxes|#default={{#var:type}}s}} from {{CountrySentence|{{CountryCode2Country|{{#var:region}}}}}}.{{#ifeq:{{NAMESPACE}}|Category|[[Category:{{#var:format}} {{#var:type}} scans]][[Category:All {{#var:region}} scans]]{{#if:{{#var:format2}}|[[Category:{{#var:format2}} {{#var:region}} {{#var:type}} scans]]}}}}</includeonly><noinclude>
 
Template to make region categories consistent. It's mostly automated, working off the category name:
 
Template to make region categories consistent. It's mostly automated, working off the category name:
  
Line 16: Line 20:
 
You can override it with "override=". You shouldn't need to though - it's more of a testing thing
 
You can override it with "override=". You shouldn't need to though - it's more of a testing thing
  
{{hr}}
+
{{clear}}
  
 
<pre>{{ScanCategory|override=Mega Drive BR box scans}}</pre>
 
<pre>{{ScanCategory|override=Mega Drive BR box scans}}</pre>
 
{{ScanCategory|override=Mega Drive BR box scans}}
 
{{ScanCategory|override=Mega Drive BR box scans}}
  
{{hr}}
+
{{clear}}
  
 
<pre>{{ScanCategory|override=32X BX box scans}}</pre>
 
<pre>{{ScanCategory|override=32X BX box scans}}</pre>
 
{{ScanCategory|override=32X BX box scans}}
 
{{ScanCategory|override=32X BX box scans}}
 +
 +
{{clear}}
 +
 +
<pre>{{ScanCategory|override=Xbox 360 JP box scans}}</pre>
 +
{{ScanCategory|override=Xbox 360 JP box scans}}
 +
 +
{{clear}}
 +
 +
<pre>{{ScanCategory|override=Xbox 360 US disc scans}}</pre>
 +
{{ScanCategory|override=Xbox 360 US disc scans}}
 +
 +
{{clear}}
 +
 +
<pre>{{ScanCategory|override=Mega Drive UK console box scans}}</pre>
 +
{{ScanCategory|override=Mega Drive UK console box scans}}
  
 
[[Category:Templates]]
 
[[Category:Templates]]
 
</noinclude>
 
</noinclude>

Latest revision as of 02:47, 1 October 2024

Template to make region categories consistent. It's mostly automated, working off the category name:

{{ScanCategory}}

You can override it with "override=". You shouldn't need to though - it's more of a testing thing


{{ScanCategory|override=Mega Drive BR box scans}}




Brazil

Scans of Mega Drive boxes from Brazil.


{{ScanCategory|override=32X BX box scans}}




Belgium Netherlands Luxembourg

Scans of 32X boxes from the Benelux region.


{{ScanCategory|override=Xbox 360 JP box scans}}




Japan

Scans of Xbox 360 boxes from Japan.


{{ScanCategory|override=Xbox 360 US disc scans}}




United States of America

Scans of Xbox 360 discs from the United States.


{{ScanCategory|override=Mega Drive UK console box scans}}




United Kingdom

Scans of Mega Drive console boxes from the United Kingdom.