Template:Itembox

From Wildfrost Wiki
Revision as of 05:36, 11 April 2023 by Landmine751 (talk | contribs)
Jump to navigation Jump to search

Description

Use this template to add an infobox to an item card's stats to the page. Itembox is designed specifically for item cards, and varies slighty to infobox, but will still nicely organize the stats on the right-hand size of the page. The itembox displays the following:

  • Card Name
  • Full card image
  • Attack
  • Other stats (e.g. Frenzy or Teeth)
  • Card description (in different colours)
  • Card art (optional, and collapsed by default)

Usage

This template can be used by entering the following onto a relevant page.

{{itembox}}

There are a number of parameters that you can add to an infobox. If a parameter is not filled in, it will show up blank.

  • name - The name displayed at the top of the infobox
  • image - The image filename, including filetype (e.g. ".png")
  • attack - Attack damage value
  • other - Additional basic stats such as Frenzy or Teeth
  • description - Card description/effects
  • desCol - Colour of the description text
  • art - The art filename, including filetype (e.g. ".png")

Samples

Scrappy Sword
Scrappy Sword.png
Attack.png Attack
1
Other Stats

Card Description
A traditional trusty weapon


{{itembox
|name=Scrappy Sword
|image=Scrappy Sword.png
|attack=1
|other-x2 {{Stat|Frenzy}}
|description=A traditional trusty weapon
|art=Scrappy Sword.png
}}

This info came from the Scrappy Sword card. Note how the values not included show up as empty boxes. This is helpful in distinguishing if there is a value present or not. Remember: a card that hits another card when activated should have an attack value, which can include 0. Cards that do not hit other cards when activating should not have an attack value. Note: the itembox will always want to display on the right-hand side with content wrapping around the remainder of the screen. The itembox itself has a fixed width.

Multiple Itemboxes

If you are trying to include multiple itembox on a page (such as this template page), you will need to include some code to reset the styling applied to the box. Without the following code, your itembox may display side-by-side. As long as the following code is between the itembox, they should display above each other.

<div style="clear:both;"></div>

In practice, this is how it should look:

{{itembox}}
<div style="clear:both;"></div>
{{itembox}}

or

{{itembox}}

Some written content goes here.

<div style="clear:both;"></div>
{{itembox}}

Whenever including multiple itembox on the same page, expect some awkward display issues. Having content long enough to space out the itembox is key in having the best presentation on a page, but it may not be easy to achieve.