Difference between revisions of "Template:Specs-Card"
Line 4: | Line 4: | ||
| 1 = {{#vardefine: type | Aviation }}{{#vardefine: typeM | aircraft }} | | 1 = {{#vardefine: type | Aviation }}{{#vardefine: typeM | aircraft }} | ||
| 2 = {{#vardefine: type | Ground vehicles }}{{#vardefine: typeM | ground vehicles }} | | 2 = {{#vardefine: type | Ground vehicles }}{{#vardefine: typeM | ground vehicles }} | ||
+ | | 3 = {{#vardefine: type | Fleet }}{{#vardefine: typeM | fleet }} | ||
+ | | 4 = {{#vardefine: type | Helicopters }}{{#vardefine: typeM | helicopters }} | ||
}}<!-- | }}<!-- | ||
-->{{#vardefine: country | | -->{{#vardefine: country | | ||
Line 23: | Line 25: | ||
--><div class="ttx"><!-- | --><div class="ttx"><!-- | ||
--><div class="ttx-title"><!-- | --><div class="ttx-title"><!-- | ||
+ | -->{{#if: {{{display_name|}}}<!-- | ||
+ | -->|{{DISPLAYTITLE:{{{display_name}}}}}[[Category:Changed visible name]]<!-- | ||
+ | -->}}<!-- | ||
-->{{#if: {{{name|}}}<!-- | -->{{#if: {{{name|}}}<!-- | ||
-->|{{{name}}}[[Category:Changed name in the card]]<!-- | -->|{{{name}}}[[Category:Changed name in the card]]<!-- | ||
-->|{{#unit: {{#var:me}} | название}}<!-- | -->|{{#unit: {{#var:me}} | название}}<!-- | ||
-->}}</div><!-- | -->}}</div><!-- | ||
− | --><div class="ttx-image">https://encyclopedia.warthunder.com/images/{{#unit: {{#var:me}} | изображение }}.png</div><!-- | + | --><div class="ttx-image">https://encyclopedia.warthunder.com/images/{{#unit: {{#var:me}} | изображение }}.png<!-- |
+ | -->{{#if: {{{cockpit|}}} |<!-- | ||
+ | --><div class="ttx-cockpit" data-id="{{{cockpit|}}}"><span>Cockpit</span></div><!-- | ||
+ | -->[[Category:With cockpit]]<!-- | ||
+ | -->}}<!-- | ||
+ | --></div><!-- | ||
-->{{#if: {{{store|}}} |<!-- | -->{{#if: {{{store|}}} |<!-- | ||
--><div class="ttx-buy"><div data-title="https://store.gaijin.net/story.php?id={{{store|}}}&partner=Wiki&partner_val=lc9fhfph" class="ttx-buy-button">СКАЧАТЬ ИГРУ</div></div><!-- | --><div class="ttx-buy"><div data-title="https://store.gaijin.net/story.php?id={{{store|}}}&partner=Wiki&partner_val=lc9fhfph" class="ttx-buy-button">СКАЧАТЬ ИГРУ</div></div><!-- | ||
Line 83: | Line 93: | ||
-->}}</span><span class="ttx-name">Class</span></div><!-- | -->}}</span><span class="ttx-name">Class</span></div><!-- | ||
--><div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | экипаж }} person</span><span class="ttx-name">Crew</span></div><!-- | --><div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | экипаж }} person</span><span class="ttx-name">Crew</span></div><!-- | ||
− | -->{{# | + | -->{{#switch: {{#var: typeIP }} |
− | |<div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | вес | пустой }} t</span><span class="ttx-name">Empty weight</span></div><!-- | + | |Aviation=<div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | вес | пустой }} t</span><span class="ttx-name">Empty weight</span></div><!-- |
--><div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | вес | полный }} t</span><span class="ttx-name">Take-off weight</span></div><!-- | --><div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | вес | полный }} t</span><span class="ttx-name">Take-off weight</span></div><!-- | ||
--><div class="ttx-table-line ttx-table-head">Flight characteristics</div><!-- | --><div class="ttx-table-line ttx-table-head">Flight characteristics</div><!-- | ||
Line 153: | Line 163: | ||
-->}}<!-- | -->}}<!-- | ||
-->}} | -->}} | ||
− | | | + | |Ground vehicles=<div class="ttx-table-line ttx-table-head">Mobility</div><!-- |
− | |||
− | |||
− | |||
− | |||
--><div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | вес }} t</span><span class="ttx-name">Weight</span></div><!-- | --><div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | вес }} t</span><span class="ttx-name">Weight</span></div><!-- | ||
--><div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | передачи | вперед }} forward<br>{{#unit: {{#var: me }} | передачи | назад }} back</span><span class="ttx-name">Gear box</span></div><!-- | --><div class="ttx-table-line"><span class="ttx-value">{{#unit: {{#var: me }} | передачи | вперед }} forward<br>{{#unit: {{#var: me }} | передачи | назад }} back</span><span class="ttx-name">Gear box</span></div><!-- |
Revision as of 10:05, 22 November 2018
Description
This template is used to create specification cards for vehicles. This template is required for Template:Specs to function properly.
Usage
{{Specs-Card |code= |images= |store= |market= |cockpit= |title_name= |card_name= }}
Parameters
- code - the code of the desired vehicle (required).
- images - the images to display on the spec card. Template:Specs-Card-Image should be used here.
- store - the store code of the vehicle (optional).
- market - the name of the vehicle on Gaijin Marketplace (optional).
- cockpit - the name of the 3D cockpit image uploaded to the wiki (optional).
- title_name - Changes the display title of the page and adds page to Category:Changed visible name (optional).
- card_name - Changes the name displayed on the stat card and adds page to Category:Changed name in the card (optional).