Template:InfoCard: Difference between revisions

From IdleOn MMO Wiki
imported>Blackwolfe
(Created page with "<includeonly> <div class="infobox"> <table><th class="header">{{PAGENAME}}</th></table> <div class="infobox-image">[[File:{{PAGENAME}} card.png]]</div> <div style="font-size:...")
 
mNo edit summary
 
(116 intermediate revisions by 10 users not shown)
Line 1: Line 1:
<includeonly>
<noinclude><!--
<div class="infobox">
<table><th class="header">{{PAGENAME}}</th></table>
<div class="infobox-image">[[File:{{PAGENAME}} card.png]]</div>
<div style="font-size: 80%; font-style: italic; text-align: center;">{{{caption|}}}</div>
<table>
<th>Category</th>
<td>{{{category}}}</td>
</tr>
<th class="subheader" colspan="2">Bonuses</th>
    </tr>
{{#if:{{{effect|}}}|<th>Effect</th>
    <td>{{{effect}}}</td>
    </tr>}}
    {{#if:{{{bonus1|}}}|<th>Base</th>
    <td>{{{bonus1}}}</td>
    </tr>}}
    {{#if:{{{bonus2|}}}|<th>[[File:Star1.png]]</th>
    <td>{{{bonus2}}}</td>
    </tr>}}
    {{#if:{{{bonus3|}}}|<th>[[File:Star2.png]]</th>
    <td>{{{bonus3}}}</td>
    </tr>}}
  {{#if:{{{bonus4|}}}|<th>[[File:Star3.png]]</th>
    <td>{{{bonus4|}}}</td>
    </tr>}}
    <th class="subheader" colspan="2">Other</th>
    </tr>
    <th style="border-radius: 0 0 0 0.4em;">Source</th>
    <td>{{{source|Source Missing!}}}</td>
    </tr></table>
</div>
[[Category:Cards]]
</includeonly>


<noinclude>
### Cargo Declare ###
-->{{#cargo_declare:_table=Cards
  |Title=String
  |CardOrder=Integer
  |Category=String (mandatory)
  |Effect=String
  |Bonus=Float
  |TierAquirements=Float
  |DropChance=Float
}}</noinclude><!--
 
### Cargo Store ###
--><includeonly>{{#cargo_store:_table=Cards
  |Title={{{title|{{PAGENAME}}}}}
  |CardOrder={{{order|-1}}}
  |Category={{{category|}}}
  |Effect={{{effect|Gosh, a card without an Effect 2%}}}
  |Bonus={{{bonus|0}}}
  |TierAquirements={{{reqtier|0}}}
  |DropChance={{{dropchance|{{#invoke:SourcesQuery|DropChance|item={{PAGENAME}}}}}}}
}}<!-- First takes dropchance parameter. If that is empty then queries the Drop table for the value.
 
--><infobox>
<title source="title">
<default>{{PAGENAME}}</default>
</title>
<image source="image">
        <default>[[File:{{PAGENAME}}.png]]</default>
    </image>
    <header>Card Bonus</header>
<data source="effect">
<label>Effect</label>
</data>
    <group name="CardBonus" layout="horizontal">
<data source="bonus">
<label>[[File:Star0.png|class=CardStar|link=]]</label>
</data>
<data source="bonus">
<label>[[File:Star1.png|class=CardStar|link=]]</label>
<format>{{#expr:{{{bonus}}}*2}}</format>
</data>
<data source="bonus">
<label>[[File:Star2.png|class=CardStar|link=]]</label>
<format>{{#expr:{{{bonus}}}*3}}</format>
</data>
<data source="bonus">
<label>[[File:Star3.png|class=CardStar|link=]]</label>
<format>{{#expr:{{{bonus}}}*4}}</format>
</data>
<data source="bonus">
<label>[[File:Star4.png|class=CardStar|link=]]</label>
<format>{{#expr:{{{bonus}}}*5}}</format>
</data>
<data source="bonus">
<label>[[File:Star5.png|class=CardStar|link=]]</label>
<format>{{#expr:{{{bonus}}}*6}}</format>
</data>
</group>
    <header>{{Tooltip|Number of cards since unlocking previous tier required to unlock indicated tier.|Tier Requirements<sup>*</sup>|nocolor=true}}</header>
    <group name="CardTier" layout="horizontal">
<data source="reqtier">
<label>[[File:Star1.png|class=CardStar|link=]]</label>
<format>{{InfoCard/TierReqForm|{{{reqtier}}}|0|{{PAGENAME}}}}</format>
</data>
<data source="reqtier">
<label>[[File:Star2.png|class=CardStar|link=]]</label>
<format>{{InfoCard/TierReqForm|{{{reqtier}}}|1|{{PAGENAME}}}}</format>
</data>
<data source="reqtier">
<label>[[File:Star3.png|class=CardStar|link=]]</label>
<format>{{InfoCard/TierReqForm|{{{reqtier}}}|2|{{PAGENAME}}}}</format>
</data>
<data source="reqtier">
<label>[[File:Star4.png|class=CardStar|link=]]</label>
<format>{{InfoCard/TierReqForm|{{{reqtier}}}|3|{{PAGENAME}}}}</format>
</data>
<data source="reqtier">
<label>[[File:Star5.png|class=CardStar|link=]]</label>
<format>{{Tooltip|Ruby Cards bonus from The Rift must be acquired in order to be able to get 6 Lv. Card. Or use 5 Star Cardifier from Gem Shop.|{{InfoCard/TierReqForm|{{{reqtier}}}|4|{{PAGENAME}}}}|nocolor=true|nospace=blahblahblah}}</format>
</data>
</group>
    <header>Other Details</header>
<data source="dropchance">
<label>Dropchance</label>
        <format>{{Chancedisplay|{{{dropchance|{{#invoke:LuaVar|var|name=Chance}}}}}}}</format>
</data>
    <data source="category">
<label>Category</label>
        <format>[[File:{{{category}}}_Cardset.png|24px]] [[Cards#{{{category}}}|{{{category}}}]]</format>
</data>
    <data source="order">
<label>Order</label>
</data>
    <data source="source">
<label>Source</label>
        <default>{{#invoke:SourcesQuery|PullSourcesFromList|item={{PAGENAME}}}}</default>
</data>
</infobox>{{#seo:
|image={{PAGENAME}}.png
|description=Category:&nbsp;{{{category}}}
{{#if: {{{effect|}}}|Effect: {{{effect}}}&#10;}}{{#if: {{{bonus|}}}|Base Bonus: {{{bonus}}}&#10;}}
}}{{{notes|}}}[[Category:Cards]]</includeonly><noinclude>
Usage
Usage
<pre>{{Card
<pre>{{InfoCard
|title=example
|order=example
|category=example
|category=example
|effect=example
|effect=example
|bonus1=example
|bonus=example
|bonus2=example
|reqtier=Base requirement for increasing tiers (as listed in the code, which in some cases is 1.5)
|bonus3=example
|bonus4=example
|source=example
}}</pre>
}}</pre>
[[category:infobox templates]]
[[category:infobox templates]]
</noinclude>
</noinclude>

Latest revision as of 02:49, 22 March 2024

This template defines the table "Cards". View table. Usage

{{InfoCard
|title=example
|order=example
|category=example
|effect=example
|bonus=example
|reqtier=Base requirement for increasing tiers (as listed in the code, which in some cases is 1.5)
}}