Template:Infobox furniture: Difference between revisions
(Added container string for container icon instead of type, adds icon to left panel. Combined skill with level, within parentheses) |
m ({{Delete|Unused}}) |
||
(12 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
<includeonly>{{Infobox | <noinclude> | ||
{{Deprecated|Infobox tile}}{{Delete|Unused}}</noinclude><includeonly>{{Infobox | |||
|bodystyle = width:350px; -moz-box-shadow: 0px 0px 2px 2px #{{Infobox nc|{{{name_colour|}}}}}; -webkit-box-shadow: 0px 0px 2px 2px #{{Infobox nc|{{{name_colour|}}}}}; box-shadow: 0px 0px 2px 2px #{{Infobox nc|{{{name_colour|}}}}}; border: 1px solid #{{Infobox nc|{{{name_colour|}}}}}; | |bodystyle = width:350px; -moz-box-shadow: 0px 0px 2px 2px #{{Infobox nc|{{{name_colour|}}}}}; -webkit-box-shadow: 0px 0px 2px 2px #{{Infobox nc|{{{name_colour|}}}}}; box-shadow: 0px 0px 2px 2px #{{Infobox nc|{{{name_colour|}}}}}; border: 1px solid #{{Infobox nc|{{{name_colour|}}}}}; | ||
| above = <div style="background: #{{Infobox nc|{{{name_colour|}}}}}; padding: 5px; font-weight: bold; text-align: center; font-size: 120%; color:#{{Infobox nc|{{{name_text_colour|}}}|text}};"><span class="fn">{{{name|{{{display_name|{{PAGENAME}}}}}}}}</span></div> | | above = <div style="background: #{{Infobox nc|{{{name_colour|}}}}}; padding: 5px; font-weight: bold; text-align: center; font-size: 120%; color:#{{Infobox nc|{{{name_text_colour|}}}|text}};"><span class="fn">{{{name|{{{display_name|{{PAGENAME}}}}}}}}</span></div> | ||
| image = {{#if: {{{image|}}}|[[File:{{{image}}}|{{{display_name}}}|{{{image_width|128px}}}]]}} | | image = {{#if: {{{image|}}}|[[File:{{{image}}}|{{{display_name}}}|{{{image_width|128px}}}|class=pixelart]]}} | ||
| caption = {{#if: {{{image_caption|}}}|''{{{image_caption|}}}''}} | | caption = {{#if: {{{image_caption|}}}|''{{{image_caption|}}}''}} | ||
| image2 = {{#if: {{{alternate_image|}}}|{{{!}} style="margin:auto;" cellspacing=5 | | image2 = {{#if: {{{alternate_image|}}}|{{{!}} style="margin:auto;" cellspacing=5 | ||
Line 26: | Line 27: | ||
| data2 = {{{category|Movable}}} | | data2 = {{{category|Movable}}} | ||
| label3 = | | label3 = Encumbrance [[File:Moodle_Icon_HeavyLoad.png|right|link=Moodles#Heavy Load|Heavy Load]] | ||
| data3 = {{{weight|}}} | | data3 = {{{weight|}}} | ||
| label4 = Size | | label4 = Size | ||
| data4 = {{#if: {{{size|}}} | {{#ifexpr: {{{size|0}}} > 1 | {{{size}}} tiles | {{{size}}} tile }} }} | | data4 = {{#if: {{{size|}}} | {{#iferror: {{#expr: {{{size}}} }} | {{error|expr|{{{size}}}}} | {{#ifexpr: {{{size|0}}} > 1 | {{{size}}} tiles | {{{size}}} tile }} }} }} | ||
| header5 = {{#if:{{{type|}}}{{{function|}}}{{{capacity|}}}{{{water_capacity|}}}{{{freezer_capacity|}}}{{{fuel|}}}{{{energy|}}}{{{contents|}}} | Properties }} | | header5 = {{#if:{{{type|}}}{{{function|}}}{{{capacity|}}}{{{water_capacity|}}}{{{freezer_capacity|}}}{{{fuel|}}}{{{energy|}}}{{{contents|}}} | Properties }} | ||
| label6 = Type {{#if: {{{container|}}} | [[File:{{#switch: {{{container}}} | Cabinet = Container_Cabinet.png | Campfire = Container_Campfire.png | Counter = Container_Counter.png | Crate = Container_Crate.png | Drawer = Container_Drawer.png | Floor = FloorTile_Icon.png | Freezer = Container_Freezer.png | Fridge = Container_Fridge.png | Garbage = Container_Garbage.png | Medicine = Container_Medicine.png | Microwave = Container_Microwave.png | Oven = Container_Oven.png|Oven]] | Plant = Container_Plant.png | Shelf = Container_Shelf.png | Vending = Container_Vending.png | Glove Box = Container_GloveCompartment.png | Seat = Container_CarSeat.png | Truck Bed = Container_TruckBed.png | Trunk = Container_CarTrunk.png | Female Corpse = DeadPerson_Female.png | Female Zombie Corpse = DeadPerson_FemaleZombie.png | Male Corpse = DeadPerson_Male.png | Male Zombie Corpse = DeadPerson_MaleZombie.png | #Default | | label6 = Type {{#if: {{{container|}}} | [[File:{{#switch: {{{container}}} | Cabinet = Container_Cabinet.png | Campfire = Container_Campfire.png | Counter = Container_Counter.png | Crate = Container_Crate.png | Drawer = Container_Drawer.png | Floor = FloorTile_Icon.png | Freezer = Container_Freezer.png | Fridge = Container_Fridge.png | Garbage = Container_Garbage.png | Medicine = Container_Medicine.png | Microwave = Container_Microwave.png | Oven = Container_Oven.png|Oven]] | Plant = Container_Plant.png | Shelf = Container_Shelf.png | Vending = Container_Vending.png | Glove Box = Container_GloveCompartment.png | Seat = Container_CarSeat.png | Truck Bed = Container_TruckBed.png | Trunk = Container_CarTrunk.png | Female Corpse = DeadPerson_Female.png | Female Zombie Corpse = DeadPerson_FemaleZombie.png | Male Corpse = DeadPerson_Male.png | Male Zombie Corpse = DeadPerson_MaleZombie.png | #Default = Container_Crate.png }}{{!}}right{{!}}link=Containers{{!}}{{{container}}}]] }} | ||
| data6 = {{{type|}}} | | data6 = {{{type|}}} | ||
Line 41: | Line 42: | ||
| label8 = Capacity | | label8 = Capacity | ||
| data8 = {{{capacity|}}} | | data8 = {{#if:{{{capacity|}}}|{{#ifeq:{{{capacity|}}}|{{#expr:{{{capacity|}}}}}|{{Tooltip|{{{capacity|}}}| {{#expr: floor({{{capacity|}}} + ({{{capacity|}}} / 100 * 30))}} with Organized trait}} | {{#iferror:{{Tooltip|{{{capacity|}}}|If you're a contributor, please manually implement a tooltip based on Large Backpack's (*container*) infobox here. Our current template sees the specified value as an expression evaluating to {{#expr:{{{capacity|}}}}}}}|{{{capacity|}}}}}}}}} | ||
| label9 = Water capacity | | label9 = Water capacity | ||
Line 47: | Line 48: | ||
| label10 = Freezer capacity | | label10 = Freezer capacity | ||
| data10 = {{{freezer_capacity|}}} | | data10 = {{#if:{{{freezer_capacity|}}}|{{#iferror: {{Tooltip|{{{freezer_capacity|}}}|Or {{#expr: floor({{{freezer_capacity|}}} + ({{{freezer_capacity|}}} / 100 * 30))}} with the Organized trait.}} | {{{freezer_capacity|}}}}}}} | ||
| label11 = Fuel/Energy | | label11 = Fuel/Energy |
Latest revision as of 06:03, 13 April 2024
This template is used to create an infobox in an article about a tiles/furniture.
Usage
To use this template in an article, copy the template below, then paste the template into an article.
All parameters are optional – those you do not populate with data will not show up in the infobox when the article is saved.
It is strongly advised to only include variables that are relevant to the specific item in question, i.e. parameters that do not display as false or 0.
{{Infobox furniture |display_name = |name_colour = |name_text_colour = |image = |image_width = |alternate_image = |alternate_name = |alternate_link = |alternate_image2 = |alternate_name2 = |alternate_link2 = |alternate_image3 = |alternate_name3 = |alternate_link3 = |alternate_image4 = |alternate_name4 = |alternate_link4 = |alternate_image5 = |alternate_name5 = |alternate_link5 = |category = |weight = |size = <!--Properties--> |type = |function = |capacity = |water_capacity = |freezer_capacity = |fuel = <!-- or | energy = --> |contents = <!--Build--> |build_skill = |build_level = |build_tool = <!-- or | build_tools = --> |ingredients = <!-- or | ingredient = --> <!--Move--> |move_skill = |move_level = |move_tool = <!-- or | move_tools = --> <!--Disassemble--> |disassemble_skill = <!-- or | dismantle_skill = --> |disassemble_level = <!-- or | dismantle_level = --> |disassemble_tool = <!-- or | disassemble_tools = --> <!-- or | products = --> <!-- or | dismantle_tool = --> <!-- or | dismantle_tools = --> |products = <!-- or | product = --> <!--Technical details--> |class_name = }}
Editors can experiment in this template's sandbox (create)