Template:Item: Difference between revisions

From StrawberryMC
CmdBlock00 (talk | contribs)
mNo edit summary
CmdBlock00 (talk | contribs)
No edit summary
Line 1: Line 1:
<noinclude>
<noinclude>
== Parameters ==
* '''name'''
* '''description'''
* '''[[Item Type|type]]'''
* '''[[Rarity|rarity]]'''
* '''image''' – Image of the item, preferably a render (e.g. `File:Tool.png`) 
* '''[[Magic Find|magicFind]]''', '''[[Fortune|fortune]]''', '''[[Blast|blast]]''' – Numerical stats 
* '''income''', '''xpMulti''' – Multiplier stats (e.g. `50%`) 
* '''[[Speed|speed]]''', '''[[Digging Power|diggingPower]]''' – Numeric only 
== Example ==
== Example ==
<pre>
<pre>
{{Item
{{Item
  | name          = Item Name
  | name          = Item Name
| image        = File:ItemImage.png
  | type          = tool
  | type          = tool
  | rarity        = epic
  | rarity        = epic
| image        = File:ItemImage.png
  | magicFind    = 10
  | magicFind    = 10
  | fortune      = 25
  | fortune      = 25
Line 16: Line 27:
}}
}}
</pre>
</pre>
== Parameters ==
* '''name''' – Name of the item
* '''type''' – Type of item (e.g. )
* '''[[rarity]]''' –
* '''image''' – Image of the item, preferably a render (e.g. `File:Tool.png`) 
* '''magicFind''', '''fortune''', '''blast''' – Numerical stats 
* '''moneyMulti''', '''xpMulti''' – Multiplier stats (e.g. `50%`) 
* '''speed''', '''diggingPower''' – Numeric only 


== Preview ==
== Preview ==
<div style="background:#fff; border:1px solid #ccc; padding:10px; margin-bottom:1em;">
<!-- LIVE TEMPLATE RENDERING FROM A SEPARATE PAGE -->
{{ItemPreviewExample}}
</div>
</noinclude>
</noinclude>


<includeonly>
<!-- Template:Item Display Code -->
<!-- Template:Item Display Code -->
<style>
.item-box {
  border: 1px solid #ccc;
  padding: 10px;
  background: #111;
  color: #fff;
  width: 300px;
  font-family: 'Minecraftia', monospace;
}
.item-box img {
  max-width: 64px;
  float: right;
  margin-left: 10px;
}
.item-name {
  font-size: 18px;
  font-weight: bold;
}
.item-rarity-common    { color: #FFFFFF; text-shadow: 0 0 2px #000; }
.item-rarity-uncommon  { color: #55FF55; text-shadow: 0 0 2px #000; }
.item-rarity-rare      { color: #5555FF; text-shadow: 0 0 2px #000; }
.item-rarity-epic      { color: #FF55FF; text-shadow: 0 0 2px #000; }
.item-rarity-legendary { color: #FFFF55; text-shadow: 0 0 2px #000; }
.item-rarity-exotic    { color: #55FFFF; text-shadow: 0 0 2px #000; }
.item-rarity-admin    { color: #FF5555; text-shadow: 0 0 2px #000; }
.item-stat {
  margin-top: 5px;
}
.item-stat-label {
  font-weight: bold;
  position: relative;
}
.item-stat-label .tooltip {
  visibility: hidden;
  background-color: #333;
  color: #fff;
  text-align: center;
  padding: 3px 6px;
  border-radius: 4px;
  position: absolute;
  z-index: 1;
  bottom: 120%;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  transition: opacity 0.2s;
  white-space: nowrap;
}
.item-stat-label:hover .tooltip {
  visibility: visible;
  opacity: 1;
}
</style>


<div class="item-box">
<div class="item-box">
Line 111: Line 51:
   {{#if:{{{diggingPower|}}}|<div class="item-stat"><span class="item-stat-label">Digging Power<span class="tooltip">Blocks you can mine</span>:</span> {{{diggingPower}}}</div>}}
   {{#if:{{{diggingPower|}}}|<div class="item-stat"><span class="item-stat-label">Digging Power<span class="tooltip">Blocks you can mine</span>:</span> {{{diggingPower}}}</div>}}
</div>
</div>
</includeonly>

Revision as of 22:54, 13 October 2025

Parameters

Example

{{Item
 | name          = Item Name
 | image         = File:ItemImage.png
 | type          = tool
 | rarity        = epic
 | magicFind     = 10
 | fortune       = 25
 | blast         = 100
 | income        = 50
 | xpMulti       = 100
 | speed         = 120
 | diggingPower  = 300
}}

Preview

   Unnamed Item