Difference between revisions of "Template:Infobox main"

From RimWorld Wiki
Jump to navigation Jump to search
m
m
Line 1: Line 1:
<noinclude>==Usage==</noinclude>
+
<noinclude>
 +
==Usage==
 +
<div class="pull-left">
 +
*Everything is optional;
 +
*You can add a "name" and "image". Fill these values if the PAGENAME macro is not adequate (if the page name has a disambig qualifier for example)
 +
<pre>
 +
{{infobox main | (animal/plant/weapon/area/structure/building/security/furniture) - used for color theme | additional styles (optional)
 +
|name = use for item header
 +
|image = picture name.(jpg/png)| variables such as size, alt text (optional)
 +
|info = use for short description
 +
|type = use for main category
 +
|type2 = use for subcategory (optional)
 +
|placeable = (yes/no) leave blank for "no"
 +
|size = two values, separated by | - (1|2)
 +
|hp = use for health/strength
 +
|speed = use for tiles
 +
|time = use for food-plants
 +
|yield = use for food-plants
 +
|power = use for power input/output (+/-)
 +
 
 +
## DON'T COPY THIS LINE ###Weapons part###
 +
|class = use for weapon class (use Single/SMG/Rifles/Thrown)
 +
|damage = use for weapon damage
 +
|range = used for weapon range
 +
|acc = use for weapon accuracy 
 +
|handling = use for weapon quick
 +
|aim = use for weapon aim time
 +
## DON'T COPY THIS LINE ##################
 +
 
 +
|buy = use for price {{mi|x}} (metal) or {{di|x} (money)
 +
|sell = use for price {{mi|x}} (metal) or {{di|x} (money)
 +
}}</pre>
 +
</div>
 +
</noinclude>
 
<div class="infobox {{#if:{{{1|}}}|{{#switch:{{{1}}}| animal = c_08 | weapon = c_25 |}}}} {{#if:{{{2}}}|{{{2|}}}}}">
 
<div class="infobox {{#if:{{{1|}}}|{{#switch:{{{1}}}| animal = c_08 | weapon = c_25 |}}}} {{#if:{{{2}}}|{{{2|}}}}}">
 
<p class="heading">{{{name|{{BASEPAGENAME}}}}}</p>
 
<p class="heading">{{{name|{{BASEPAGENAME}}}}}</p>
Line 36: Line 69:
 
{{#if: {{{dmg|}}}|
 
{{#if: {{{dmg|}}}|
 
;Damage
 
;Damage
:{{{dmg|}}}}}
+
:{{{damage|}}}}}
 
{{#if: {{{range|}}}|
 
{{#if: {{{range|}}}|
 
;Range
 
;Range
Line 62: Line 95:
 
</includeonly>
 
</includeonly>
 
<noinclude>
 
<noinclude>
<div class="pull-left">
 
*Everything is optional;
 
*You can add a "name" and "image". Fill these values if the PAGENAME macro is not adequate (if the page name has a disambig qualifier for example)
 
<pre>
 
{{infobox main | (animal/plant/weapon/area/structure/building/security/furniture) - used for color theme | additional styles (optional)
 
|name = use for item header
 
|image = picture name.(jpg/png)| variables such as size, alt text (optional)
 
|info = use for short description
 
|type = use for main category
 
|type2 = use for subcategory (optional)
 
|placeable = (yes/no) leave blank for "no"
 
|size = two values, separated by | - (1|2)
 
|hp = use for health/strength
 
|speed = use for tiles
 
|time = use for food-plants
 
|yield = use for food-plants
 
|power = use for power input/output (+/-)
 
 
## DON'T COPY THIS LINE ###Weapons part###
 
|class = use for weapon class (use Single/SMG/Rifles/Thrown)
 
|damage = use for weapon damage
 
|range = used for weapon range
 
|acc = use for weapon accuracy 
 
|handling = use for weapon quick
 
|aim = use for weapon aim time
 
## DON'T COPY THIS LINE ##################
 
 
|buy = use for price {{mi|x}} (metal) or {{di|x} (money)
 
|sell = use for price {{mi|x}} (metal) or {{di|x} (money)
 
}}</pre></div>
 
 
{{clear}}
 
{{clear}}
==Example==
+
==Example #1==
<div class="pull-left"><pre>
 
 
{{infobox main|animal|pull-left
 
{{infobox main|animal|pull-left
 
|name = Muffalo
 
|name = Muffalo
Line 104: Line 106:
 
|buy = {{mi|1}}
 
|buy = {{mi|1}}
 
|sell= {{di|2}}
 
|sell= {{di|2}}
}}</pre></div>
+
}}
 +
<div class="pull-left"><pre>
 
{{infobox main|animal|pull-left
 
{{infobox main|animal|pull-left
 
|name = Muffalo
 
|name = Muffalo
Line 114: Line 117:
 
|buy = {{mi|1}}
 
|buy = {{mi|1}}
 
|sell= {{di|2}}
 
|sell= {{di|2}}
 +
}}</pre></div>
 +
{{clear}}
 +
==Example #2==
 +
{{infobox main|weapon|pull-left
 +
|name = Pistol
 +
|image = Equipment Pistol.png|Pistol
 +
|type = Equipment
 +
|type2 = Weapons
 +
|info = "Ancient pattern automatic pistol. Weak and short range, but quick."
 +
|placeable = y
 +
|class = Single shot
 +
|damage = 10
 +
|range = 24
 +
|acc = 4
 +
|handling = Quick
 +
|aim = 1.1
 +
|buy  = {{di|250}}
 
}}
 
}}
 +
<div class="pull-left"><pre>
 +
{{infobox main|weapon|pull-left
 +
|name = Pistol
 +
|image = Equipment Pistol.png|Pistol
 +
|type = Equipment
 +
|type2 = Weapons
 +
|info = "Ancient pattern automatic pistol. Weak and short range, but quick."
 +
|placeable = y
 +
|class = Single shot
 +
|damage = 10
 +
|range = 24
 +
|acc = 4
 +
|handling = Quick
 +
|aim = 1.1
 +
|buy  = {{di|250}}
 +
}}</pre></div>
 +
 
[[Category:Infobox templates|Main]]
 
[[Category:Infobox templates|Main]]
 
</noinclude>
 
</noinclude>

Revision as of 16:43, 13 November 2013

Usage

  • Everything is optional;
  • You can add a "name" and "image". Fill these values if the PAGENAME macro is not adequate (if the page name has a disambig qualifier for example)
{{infobox main | (animal/plant/weapon/area/structure/building/security/furniture) - used for color theme | additional styles (optional)
|name = use for item header 
|image = picture name.(jpg/png)| variables such as size, alt text (optional)
|info = use for short description
|type = use for main category 
|type2 = use for subcategory (optional)
|placeable = (yes/no) leave blank for "no"
|size = two values, separated by | - (1|2)
|hp = use for health/strength
|speed = use for tiles 
|time = use for food-plants
|yield = use for food-plants
|power = use for power input/output (+/-)

## DON'T COPY THIS LINE ###Weapons part###
|class = use for weapon class (use Single/SMG/Rifles/Thrown)
|damage = use for weapon damage
|range = used for weapon range
|acc = use for weapon accuracy  
|handling = use for weapon quick
|aim = use for weapon aim time
## DON'T COPY THIS LINE ##################

|buy = use for price {{mi|x}} (metal) or {{di|x} (money)
|sell = use for price {{mi|x}} (metal) or {{di|x} (money)
}}

Infobox main

File:Infobox main.png

Type
[[{{{type}}}]]
Placeable
no


Example #1

Muffalo

Muffalo

Slow-moving, grass-grazing quadrupeds analogous to Buffalo.


Type
Animals
Placeable
no
HP
200
Buy / Sell
Template:Mi / Template:Di


{{infobox main|animal|pull-left
|name = Muffalo
|image = Animal Muffalo side.png|200px{{!}}Muffalo
|info = Slow-moving, grass-grazing quadrupeds analogous to Buffalo.
|type = Animals
|placeable =
|hp = 200
|buy = {{mi|1}}
|sell= {{di|2}}
}}

Example #2

Pistol

Pistol

"Ancient pattern automatic pistol. Weak and short range, but quick."


Type
Equipment – Weapons
Placeable
yes
Class
Single shot
Range
24
Handling
Quick
Aim time
1.1 sec.
Buy
Template:Di


{{infobox main|weapon|pull-left
|name = Pistol
|image = Equipment Pistol.png|Pistol
|type = Equipment
|type2 = Weapons
|info = "Ancient pattern automatic pistol. Weak and short range, but quick."
|placeable = y
|class = Single shot
|damage = 10
|range = 24
|acc = 4
|handling = Quick
|aim = 1.1
|buy  = {{di|250}}
}}