Template:Infobox item: Difference between revisions

From Ultimate Dragon Ball Online Wiki

Ollix (talk | contribs)
Created page with "<includeonly><templatestyles src="Template:Infobox item/styles.css" />{{#ifeq:{{{quote|}}}|||<blockquote style="font-style:italic">"{{{quote}}}"</blockquote>}}<infobox> <title source="name"> <default>{{PAGENAME}}</default> </title> <image source="icon"> <default>{{{thumbnail|{{{name|{{PAGENAME}}}}}.png}}}</default> <caption source="icon-caption"><default>{{{thumbnail-caption|}}}</default></caption> </image> <group> <data> <label>Rarity</label> <default..."
 
Ollix (talk | contribs)
No edit summary
 
(143 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly><templatestyles src="Template:Infobox item/styles.css" />{{#ifeq:{{{quote|}}}|||<blockquote style="font-style:italic">"{{{quote}}}"</blockquote>}}<infobox>
{| class="infobox" style="border: 1px solid #ccc; width: 250px; background-color: #f9f9f9; font-family: Arial, sans-serif; margin: 0 auto; border-radius: 10px;"
<title source="name">
! colspan="2" style="background-color: #2161c0; color: white; text-align: center; font-size: 1.25em; font-weight: bold; padding: 5px 0; border-top-left-radius: 10px; border-top-right-radius: 10px;" | <span style="font-weight: bold; text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000; text-align: center;">{{#if: {{{title|}}} | {{{title}}} | {{PAGENAME}} }}</span>{{#if: {{{rarity|Common}}} | <br /><span style="font-size: 0.9em; font-weight: bold; text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000; color: {{#switch: {{{rarity}}}
<default>{{PAGENAME}}</default>
  | Common = #64ff77  <!-- White -->
</title>
  | Superior = #99bbee  <!-- Blue -->
<image source="icon">
  | Excellent = #ffdd66  <!-- Yellow -->
<default>{{{thumbnail|{{{name|{{PAGENAME}}}}}.png}}}</default>
  | Rare = #ff6677  <!-- Red -->
<caption source="icon-caption"><default>{{{thumbnail-caption|}}}</default></caption>
  | Legendary = #ee77dd  <!-- Magenta -->
</image>
  | default = #ffffff }}">{{{rarity|<span style="font-size: 0.9em; font-weight: bold; text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000; color: #64ff77;>Common</span>}}}</span>}}
<group>
|-
<data>
| colspan="2" style="text-align: center; padding-top: 10px; padding-bottom: 10px;" | [[File:{{#if: {{{icon|}}} | {{{icon}}} | item_no_icon.png }}|32px]]
<label>Rarity</label>
|-
<default>{{#switch:{{{rarity}}}
| colspan="2" style="border-radius: 10px; background-color: #efefef; color: #555555; text-align: center; padding: 10px; font-style: italic;" | {{{description|}}}
|Legendary=[[Category:Legendary]][[:Category:Legendary|<span class="rarity-Legendary">Legendary</span>]]
|-
|Epic=[[Category:Epic]][[:Category:Epic|<span class="rarity-Epic">Epic</span>]]
! colspan="2" style="background-color: #dcdcdc; color: black; text-align: center; font-size: 1.1em; font-weight: bold; padding: 5px;" | General Information
|Rare=[[Category:Rare]][[:Category:Rare|<span class="rarity-Rare">Rare</span>]]
|-
|Standard=[[Category:Standard]][[:Category:Standard|<span class="rarity-Standard">Standard</span>]]
{{#if: {{{class|}}} |
|Normal=[[Category:Normal]][[:Category:Normal|<span class="rarity-Normal">Normal</span>]]
! <span style="display: inline-block; text-align: left; padding-left: 10px; width: 100%;">Class</span>
|{{#ifeq:{{{rarity|}}}|||[[Category:Infoboxes with Invalid Parameter]]{{{rarity}}}*}}
{{!}}<span style="font-weight: bold; text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000; color: {{#switch: {{{class}}}
}}</default>
  | Human = #fed851  <!-- Orange -->
</data>
  | Namek = #98fa80  <!-- Green -->
<data source="category">
  | Majin = #ffb4ca  <!-- Pink -->
  <label>Category</label>
  | default = #ffffff }}">{{{class}}}</span>
<default>{{#switch:{{{category}}}
}}
|Tools=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
|-
|Consumables=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
{{#if: {{{level|}}} |
|Materials=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
! <span style="display: inline-block; text-align: left; padding-left: 10px; width: 100%;">Level</span>
|Special=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
{{!}}<span style="display: inline-block; width: 100%;">{{{level}}}</span>
|Construction=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
}}
|Deviations=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
|-
|Armor=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
{{#if: {{{slot|}}} |
|Cosmetic=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
! <span style="display: inline-block; text-align: left; padding-left: 10px; width: 100%;">Slot</span>
|Currencies=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
{{!}}<span style="display: inline-block; width: 100%;">{{{slot}}}</span>
|Mods=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
}}
|Weapons=[[Category:{{{category}}}]][[:Category:{{{category}}}|{{{category}}}]]
|-
|{{#ifeq:{{{category|}}}|||[[Category:Infoboxes with Invalid Parameter]]{{{category}}}*}}
{{#if: {{{weight|}}} |
}}</default>
! <span style="display: inline-block; text-align: left; padding-left: 10px; width: 100%;">Weight</span>
</data>
{{!}}<span style="display: inline-block; width: 100%;">{{{weight}}}</span>
<data>
}}
<label>Type</label>
|-
<default>{{#switch:{{{type}}}
{{#if: {{{npc_price|}}} |
|Armor Mods=[[Category:{{{type}}}]][[:Category:{{{type}}}|{{{type}}}]]-[[Category:{{{type}}}-{{{mod_type}}}]][[:Category:{{{type}}}-{{{mod_type}}}|{{{mod_type}}}]]
! <span style="display: inline-block; text-align: left; padding-left: 10px; width: 100%;">NPC Price</span>
|Weapon Mods=[[Category:{{{type}}}]][[:Category:{{{type}}}|{{{type}}}]]-[[Category:{{{type}}}-{{{mod_type}}}]][[:Category:{{{type}}}-{{{mod_type}}}|{{{mod_type}}}]]
{{!}}<span style="display: inline-block; width: 100%;">{{{npc_price}}} [[File:Ui_icon_zeni.png|16px]]</span>
|Mod=[[Category:{{{type}}}]][[:Category:{{{type}}}|{{{type}}}]]
}}
|{{#ifeq:{{{type|}}}||[[Category:Items Missing Type Parameter]]*|[[:Category:{{{type}}}|{{{type}}}]][[Category:{{{type}}}|{{{type}}}]]}}
|-
  }}</default>
| colspan="2" style="padding-bottom: 5px;" | <!-- This row adds space at the bottom -->
</data>
|}
<data source="linked">
 
  <label>Linked</label>
<noinclude>
<default>{{#switch:{{{linked}}}
== Infobox Usage Guide ==
|Always=[[Category:Linked-{{{linked}}}]][[:Category:Linked-{{{linked}}}|{{{linked}}}]]
{| class="wikitable"
|Source dependent=[[Category:Linked-{{{linked}}}]][[:Category:Linked-{{{linked}}}|{{{linked}}}]]
|-
|Seasonal transfer only=[[Category:Linked-{{{linked}}}]][[:Category:Linked-{{{linked}}}|{{{linked}}}]]
! Example Code !! Example Result
|Never=[[Category:Linked-{{{linked}}}]][[:Category:Linked-{{{linked}}}|{{{linked}}}]]
|-
|{{#ifeq:{{{linked|}}}|||[[Category:Infoboxes with Invalid Parameter]]{{{linked}}}*}}
| <pre>
}}</default>
{{Infobox_item
</data>
| title      = Classic Magic Rubber Suit (Top)
<data source="seasonal_inheritance">
| icon        = Infobox_armor_example_icon.png
  <label>Seasonal Inheritance</label>
| description = Advanced materials are used to make this, completely without regard to cost.
<default>{{#switch:{{{seasonal_inheritance}}}
| rarity      = Rare
|Unlimited=[[Category:Seasonal-Inheritance-{{{seasonal_inheritance}}}]][[:Category:Seasonal-Inheritance-{{{seasonal_inheritance}}}|{{{seasonal_inheritance}}}]]
| class      = Majin
|Spacetime Backpack=[[Category:Seasonal-Inheritance-{{{seasonal_inheritance}}}]][[:Category:Seasonal-Inheritance-{{{seasonal_inheritance}}}|{{{seasonal_inheritance}}}]]
| level      = 20
|None=[[Category:Seasonal-Inheritance-{{{seasonal_inheritance}}}]][[:Category:Seasonal-Inheritance-{{{seasonal_inheritance}}}|{{{seasonal_inheritance}}}]]
| slot        = Jacket
|{{#ifeq:{{{seasonal_inheritance|}}}|||[[Category:Infoboxes with Invalid Parameter]]{{{seasonal_inheritance}}}*}}
| weight      = 350
}}</default>
| npc_price  = 1,649
</data>
}}
<data source="tradeability">
</pre>
  <label>Tradeability</label>
| {{Infobox_item
<default>{{#switch:{{{seasonal_inheritance}}}
| title      = Classic Magic Rubber Suit (Top)
|Universal=[[Category:-{{{tradeability}}}]][[:Category:Tradeability-{{{tradeability}}}|{{{tradeability}}}]]
| icon        = Infobox_armor_example_icon.png
|Energy Link=[[Category:-{{{tradeability}}}]][[:Category:Tradeability-{{{tradeability}}}|{{{tradeability}}}]]
| description = Advanced materials are used to make this, completely without regard to cost.
|Discardable=[[Category:-{{{tradeability}}}]][[:Category:Tradeability-{{{tradeability}}}|{{{tradeability}}}]]
| rarity      = Rare
|No=[[Category:-{{{tradeability}}}]][[:Category:Tradeability-{{{tradeability}}}|{{{tradeability}}}]]
| class      = Majin
|{{#ifeq:{{{tradeability|}}}|||[[Category:Infoboxes with Invalid Parameter]]{{{tradeability}}}*}}
| level      = 20
}}</default>
| slot        = Jacket
</data>
| weight      = 350
<data source="weight">
| npc_price  = 1,649
  <label>Weight</label>
}}
</data>
|}
<data source="stack_size">
 
  <label>Stack Size</label>
=== Parameter Explanations ===
</data>
 
<data source="durability">
* '''title''': The name of the item. Defaults to the page name if not provided.
<label>Durability</label>
* '''icon''': The filename of the item's icon (e.g., ''ItemIcon.png''). Defaults to ''item_no_icon.png'' if not provided.
</data>
* '''description''': A brief description of the item.
<data source="durability_fridge">
* '''Weight''': The weight of the item.
<label>Refrigerated</label>
* '''Event Item''': Indicates if the item is exclusive to events. Accepts ''Yes'' or ''No''. Displays a checkmark (✅) for ''Yes'' and a cross (❌) for ''No''.
</data>
* '''Rarity''': The rarity level of the item. Accepts values like ''Common'', ''Superior'', ''Excellent'', ''Rare'', or ''Legendary''. Each value is color-coded:
</group>
  - ''Common'': White (''#ffffff'')
<group>
  - ''Superior'': Light Blue (''#99bbee'')
<data>
  - ''Excellent'': Yellow (''#ffdd66'')
<label>Buy Price(s)</label>
  - ''Rare'': Red (''#ff6677'')
<default>{{#ifeq:{{{pricebuy_links|}}}|||{{Energy Links|{{{pricebuy_links}}}}}<br/>}}{{#ifeq:{{{pricebuy_starchrom|}}}|||{{Starchrom|{{{pricebuy_starchrom}}}}}<br/>}}{{#ifeq:{{{pricebuy_planula|}}}|||{{Stellar Planula|{{{pricebuy_planula}}}}}<br/>}}{{#ifeq:{{{pricebuy_sproutlets|}}}|||{{Sproutlets|{{{pricebuy_sproutlets}}}}}<br/>}}{{#ifeq:{{{pricebuy_marks|}}}|||{{Mitsuko Marks|{{{pricebuy_marks}}}}}<br/>}}{{#ifeq:{{{pricebuy_material_points|}}}|||Material Points:{{{pricebuy_material_points}}}<br/>}}</default>
  - ''Legendary'': Pink (''#ee77dd'')
</data>
* '''Class''': The class that can use the item.
</group>
* '''Level''': The required level to use the item.
<group>
* '''Slot''': The equipment slot where this item is placed (e.g., ''Weapon'', ''Armor'').
<data>
* '''NPC Price''': The price of the item when sold to NPC vendors.
<label>Sell Price(s)</label>
 
            <default>{{#ifeq:{{{pricesell_links|}}}|||{{Energy Links|{{{pricesell_links}}}}}<br/>}}{{#ifeq:{{{pricesell_astral|}}}|||{{Astral Sand|{{{pricesell_astral}}}}}<br/>}}</default>
=== Notes ===
</data>
 
</group>
* If a parameter is left blank, it will not be displayed in the infobox.
    <group>
* Ensure that image files (e.g., icons) are correctly uploaded to the wiki for them to appear.
<data>
* Proper formatting and consistent use of parameters ensure uniformity across pages.
<label>Location</label>
 
<default>{{#ifeq:{{{location|}}}|||[[{{{location}}}]]}}</default>
</noinclude>
</data>
<data>
<label>Coordinates</label>
<default>{{#ifeq:{{{coordinates|}}}|||{{Coordinates|{{{coordinates}}}}}}}</default>
</data>
    </group>
<group>
<data source="growth_cycle">
<label>Growth Cycle</label>
</data>
<data source="irrigation">
<label>Irrigation</label>
</data>
<data source="lighting">
<label>Lighting</label>
</data>
</group>
<group>
<data source="status_energy">
  <label>Energy</label>
</data>
<data source="status_hp">
  <label>HP</label>
</data>
<data source="status_hydration">
  <label>Hydration</label>
</data>
<data source="status_sanity">
  <label>Sanity</label>
</data>
<data>
<default>{{#if:{{{status_effects|}}}|'''Status Effects:'''<span class="oh-h2g-indented">{{{status_effects}}}</span>}}</default>
</data>
<data>
<default>{{#if:{{{core_effect|}}}|'''Core Effect:'''<span class="oh-h2g-indented">{{{core_effect}}}</span>}}</default>
</data>
<data>
<default>{{#if:{{{attribute_effects|}}}|'''Attribute Effects:'''<span class="oh-h2g-indented">{{{attribute_effects}}}</span>}}</default>
</data>
    </group>
<group>
<data source="xp">
<label>XP</label>
</data>
<data source="xp_battlepass">
<label>Battle Pass XP</label>
</data>
</group>
<group>
  <header>How To Get</header>
  <data><default>
    {{Howtoget
|build={{{build|}}}
|brewing_barrel={{{brewing_barrel|}}}
|campsite={{{campsite|}}}
|commissions={{{commissions|}}}
|contaminated_water={{{contaminated_water|}}}
|crisis_event={{{crisis_event|}}}
|disassembly={{{disassembly|}}}
|dungeons={{{dungeons|}}}
|explore_wilderness={{{explore_wilderness|}}}
|explore_settlements={{{explore_settlements|}}}
|explore_strongholds={{{explore_strongholds|}}}
|fell_trees={{{fell_trees|}}}
|fishing={{{fishing|}}}
|fresh_water={{{fresh_water|}}}
|furnace={{{furnace|}}}
|furnace_electric={{{furnace_electric|}}}
|gathering={{{gathering|}}}
|gear_workbench={{{gear_workbench|}}}
|gear_workbench_intermediate={{{gear_workbench_intermediate|}}}
|gear_workbench_advanced={{{gear_workbench_advanced|}}}
|hunting={{{hunting|}}}
|kitchen={{{kitchen|}}}
|loot={{{loot|}}}
|memetic={{{memetic|}}}
|memetic_specialization={{{memetic_specialization|}}}
|mining={{{mining|}}}
|refining_facility={{{refining_facility|}}}
|season_shop={{{season_shop|}}}
|securement_unit={{{securement_unit|}}}
|shop_stellarplanula={{{shop_stellarplanula|}}}
|stove={{{stove|}}}
|stove_electric={{{stove_electric|}}}
|supplies_workbench={{{supplies_workbench|}}}
|supplies_workbench_intermediate={{{supplies_workbench_intermediate|}}}
|supplies_workbench_advanced={{{supplies_workbench_advanced|}}}
|synthesis_bench={{{synthesis_bench|}}}
|synthesis_bench_advanced={{{synthesis_bench_advanced|}}}
|warband_activity={{{warband_activity|}}}
|water_filter={{{water_filter|}}}
|water_purifier={{{water_purifier|}}}
|workshop_defense={{{workshop_defense|}}}
}}
  </default></data>
</group>
</infobox>

Latest revision as of 04:31, 20 March 2025

Infobox item
Common
General Information


Infobox Usage Guide

Example Code Example Result
{{Infobox_item
 | title       = Classic Magic Rubber Suit (Top)
 | icon        = Infobox_armor_example_icon.png
 | description = Advanced materials are used to make this, completely without regard to cost.
 | rarity      = Rare
 | class       = Majin
 | level       = 20
 | slot        = Jacket
 | weight      = 350
 | npc_price   = 1,649
}}
Classic Magic Rubber Suit (Top)
Rare
Advanced materials are used to make this, completely without regard to cost.
General Information
Class Majin
Level 20
Slot Jacket
Weight 350
NPC Price 1,649


Parameter Explanations

  • title: The name of the item. Defaults to the page name if not provided.
  • icon: The filename of the item's icon (e.g., ItemIcon.png). Defaults to item_no_icon.png if not provided.
  • description: A brief description of the item.
  • Weight: The weight of the item.
  • Event Item: Indicates if the item is exclusive to events. Accepts Yes or No. Displays a checkmark (✅) for Yes and a cross (❌) for No.
  • Rarity: The rarity level of the item. Accepts values like Common, Superior, Excellent, Rare, or Legendary. Each value is color-coded:
 - Common: White (#ffffff)
 - Superior: Light Blue (#99bbee)
 - Excellent: Yellow (#ffdd66)
 - Rare: Red (#ff6677)
 - Legendary: Pink (#ee77dd)
  • Class: The class that can use the item.
  • Level: The required level to use the item.
  • Slot: The equipment slot where this item is placed (e.g., Weapon, Armor).
  • NPC Price: The price of the item when sold to NPC vendors.

Notes

  • If a parameter is left blank, it will not be displayed in the infobox.
  • Ensure that image files (e.g., icons) are correctly uploaded to the wiki for them to appear.
  • Proper formatting and consistent use of parameters ensure uniformity across pages.