Template:BlockInfoBox: Difference between revisions
Appearance
No edit summary |
No edit summary Tag: Manual revert |
||
(30 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<span> | |||
<includeonly> | |||
<table id="BlockInfoBox" class="game-infobox"> | |||
<tr><th colspan="2" class="game-infobox-title">{{{title|}}}</th></tr> | |||
<tr><td colspan="2">{{{model|}}}</td></tr> | |||
<tr><th colspan="2" class="game-infobox-header">General Attributes:</th></tr> | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Block ID</strong></td> | |||
<td style="border-left: 0" class="game-infobox-argument">{{{id|0}}}</td></tr> | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Stackable</strong></td> | |||
<td style="border-left: 0" class="game-infobox-argument"> | |||
{{#switch: {{{isStackable|}}} | |||
| #default = Yes | |||
| yes = Yes | |||
| Yes = Yes | |||
| no = No | |||
| No = No}} ({{{maxStackSize|0}}})</td></tr> | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Flammable</strong></td> | |||
<td style="border-left: 0" class="game-infobox-argument"> | |||
{{#if:{{{isFlammable|}}}| | |||
{{#switch: {{{isFlammable|}}} | |||
| #default = [[File:no.webp|20x20px]] | |||
| yes = [[File:yes.webp|18x18px]] | |||
| Yes = [[File:yes.webp|18x18px]] | |||
| no = [[File:no.webp|20x20px]] | |||
| No = [[File:no.webp|20x20px]]}}}}</td></tr> | |||
{{#if:{{{isEdible|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Edible</strong></td> | |||
<td style="border-left: 0" class="game-infobox-argument"> | |||
{{#switch: {{{isEdible|}}} | |||
| #default = [[File:no.webp|20x20px]] | |||
| yes = [[File:yes.webp|18x18px]] | |||
| Yes = [[File:yes.webp|18x18px]] | |||
| no = [[File:no.webp|20x20px]] | |||
| No = [[File:no.webp|20x20px]]}}}}</td></tr> | |||
{{#if:{{{isSleepable|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Sleep Suitability</strong></td> | |||
<td style="border-left: 0" class="game-infobox-argument"> | |||
{{#switch: {{{isSleepable|}}} | |||
| #default = [[File:no.webp|20x20px]] | |||
| yes = [[File:yes.webp|18x18px]] | |||
| Yes = [[File:yes.webp|18x18px]] | |||
| no = [[File:no.webp|20x20px]] | |||
| No = [[File:no.webp|20x20px]]}}}}</td></tr> | |||
{{#if:{{{fuelValue|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Fuel Value</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{fuelValue|0}}}</td></tr>}} {{#if:{{{fuelValue|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Fire Duration</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{fireDuration|0}}}</td></tr>}} {{#if:{{{foodType|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Food Type</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{foodType}}}</td></tr>}} {{#if:{{{nutritionalValue|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Food Type</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{nutritionalValue|0}}}</td></tr>}} {{#if:{{{emittedLightAmount|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Emitted Light Amount</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{emittedLightAmount|0}}</td></tr>}} | |||
<tr><th colspan="2" class="game-infobox-header">Physics:</th></tr> | |||
{{#if:{{{lightAttenuation|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Light Attenuation</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{lightAttenuation|0}}}</td></tr>}} {{#if:{{{explosivePower|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Explosive Power</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{explosivePower|0}}}</td></tr>}} {{#if:{{{explosionResilience|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Explosion Resilience</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{explosionResilience|0}}}</td></tr>}} {{#if:{{{projectileResilience|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Projectile Resilience</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{projectileResilience|0}}}</td></tr>}} {{#if:{{{density|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Density</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{density|0}}}</td></tr>}} | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Fluid Blocker</strong></td> | |||
<td style="border-left: 0" class="game-infobox-argument"> | |||
{{#switch: {{{isFluidBlocker|}}} | |||
| #default = [[File:no.webp|20x20px]] | |||
| yes = [[File:yes.webp|18x18px]] | |||
| Yes = [[File:yes.webp|18x18px]] | |||
| no = [[File:no.webp|20x20px]] | |||
| No = [[File:no.webp|20x20px]]}}</td></tr> | |||
{{#if:{{{projectileStickProbability|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Projectile Stick Probability</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{projectileStickProbability|0}}}</td></tr>}} | |||
<tr><th colspan="2" class="game-infobox-header">Tool-Related Attributes:</th></tr> | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Digging Method</strong></td> | |||
<td style="border-left: 0" class="game-infobox-argument"> | |||
{{#switch: {{{diggingMethod|}}} | |||
| #default = Hack | |||
| hack = Hack | |||
| Hack = Hack | |||
| axe = Hack | |||
| Axe = Hack | |||
| quarry = Quarry | |||
| Quarry = Quarry | |||
| pickaxe = Quarry | |||
| Pickaxe = Quarry | |||
| shovel = Shovel | |||
| Shovel = Shovel}}</td></tr> | |||
{{#if:{{{diggingResilience|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Digging Resilience</strong></td><td style="border-left: 0;" class="game-infobox-argument">{{{diggingResilience|0}}}</td></tr>}} {{#if:{{{requiredToolLevel|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Required Tool Level</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{requiredToolLevel|0}}}</td></tr>}} {{#if:{{{experienceGiven|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Experience Given</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{experienceGiven|0}}}</td></tr>}} {{#if:{{{toolDurabilityImpact|}}}| | |||
<tr><td style="border-right: 0" class="game-infobox-attribute"><strong>Tool Durability Impact</strong></td><td style="border-left: 0" class="game-infobox-argument">{{{toolDurabilityImpact|0}}}</td></tr>}} | |||
</table> | |||
</includeonly> | |||
</span> | |||
<span> | <span> | ||
<noinclude> | <noinclude> | ||
Line 59: | Line 148: | ||
"nutritionalValue": { | "nutritionalValue": { | ||
"label": "Nutritional Value", | "label": "Nutritional Value", | ||
"type": "number" | "type": "number", | ||
"description": "How many food points/bars the item provides upon consumption.", | |||
"default": "0" | |||
}, | }, | ||
"emittedLightAmount": { | "emittedLightAmount": { | ||
Line 141: | Line 232: | ||
"type": "number", | "type": "number", | ||
"default": "0" | "default": "0" | ||
}, | |||
"title": { | |||
"label": "Block/Item Title", | |||
"description": "Name of the block/item.", | |||
"example": "\"Stone Brick\" or \"Iron Machete\"", | |||
"type": "string", | |||
"required": true | |||
}, | |||
"model": { | |||
"label": "Block/Item Model", | |||
"description": "Source for block/item model or image. Templates are recommended but static files can be passed as well.", | |||
"example": "{{#widget:ModelViewer|parameters}} or [[File:filename.extension|imageSize]]", | |||
"type": "wiki-template-name", | |||
"required": true | |||
}, | |||
"id": { | |||
"label": "Block ID", | |||
"description": "Block identification number.", | |||
"type": "number", | |||
"default": "0", | |||
"required": true | |||
} | } | ||
}, | }, | ||
"description": "Embeds a customized infobox for displaying block/item attributes along the left side of a wiki page. Can be used in conjunction with the Widget:ModelViewer for displaying block/item models.", | "description": "Embeds a customized infobox for displaying block/item attributes along the left side of a wiki page. Can be used in conjunction with the Widget:ModelViewer for displaying block/item models.", | ||
"paramOrder": [ | "paramOrder": [ | ||
"title", | |||
"model", | |||
"id", | |||
"isStackable", | "isStackable", | ||
"maxStackSize", | "maxStackSize", |