Template:StatTable: Difference between revisions
Jump to navigation
Jump to search
No edit summary Tag: Reverted |
No edit summary Tag: Reverted |
||
| Line 1: | Line 1: | ||
<includeonly><templatestyles src="Template:StatTable/styles.css"/> | <includeonly><templatestyles src="Template:StatTable/styles.css"/> | ||
<div class="statbox"> | <div class="statbox"> | ||
<table style="border-color:{{{frame|#444}}};"> | <table style="border-color:{{{frame|#444}}};"> | ||
<thead> | |||
<tr> | |||
<th class="hdr-stat" colspan="2" rowspan="2">Stat</th> | |||
<th class="hdr-range" colspan="2">Range</th> | |||
</tr> | |||
<tr> | |||
<th class="hdr-sub">At Lv 50</th> | |||
<th class="hdr-sub">At Lv 100</th> | |||
</tr> | |||
</thead> | |||
<tbody> | |||
<!-- HP --> | |||
<tr class="row-hp"> | |||
<td class="lab">HP:<span>{{{HP}}}</span></td> | |||
<td class="bar"> | |||
<div class="fill" | |||
style="width:{{#expr:({{{HP|0}}}*100/255) round 0}}%;"></div> | |||
</td> | |||
<td class="range"><small> | |||
{{#ifexpr:{{{HP}}}=1|1 | |||
|{{#expr:((0+2*{{{HP}}}+(0/4))*50/100)+10+50}}}} – | |||
{{#ifexpr:{{{HP}}}=1|1 | |||
|{{#expr:((31+2*{{{HP}}}+(252/4))*50/100)+10+50}}}} | |||
</small></td> | |||
<td class="range"><small> | |||
{{#ifexpr:{{{HP}}}=1|1 | |||
|{{#expr:((0+2*{{{HP}}}+(0/4))*100/100)+10+100}}}} – | |||
{{#ifexpr:{{{HP}}}=1|1 | |||
|{{#expr:((31+2*{{{HP}}}+(252/4))*100/100)+10+100}}}} | |||
</small></td> | |||
</tr> | |||
<!-- Attack --> | |||
<tr class="row-atk"> | |||
<td class="lab">Attack:<span>{{{Attack}}}</span></td> | |||
<td class="bar"> | |||
<div class="fill" | |||
style="width:{{#expr:({{{Attack|0}}}*100/255) round 0}}%;"></div> | |||
</td> | |||
<td class="range"><small> | |||
{{#expr:floor((((0+2*{{{Attack}}}+(0/4))*50/100)+5)*.9)}}}} – | |||
{{#expr:floor((((31+2*{{{Attack}}}+(252/4))*50/100)+5)*1.1)}}}} | |||
</small></td> | |||
<td class="range"><small> | |||
{{#expr:floor((((0+2*{{{Attack}}}+(0/4))*100/100)+5)*.9)}}}} – | |||
{{#expr:floor((((31+2*{{{Attack}}}+(252/4))*100/100)+5)*1.1)}}}} | |||
</small></td> | |||
</tr> | |||
<!-- …and repeat the same 4-<td> pattern for Defense, SpAtk, SpDef, Speed… --> | |||
<!-- Total --> | |||
<tr class="total"> | |||
<td class="lab">Total:<span> | |||
{{#expr: | |||
{{{HP}}}+{{{Attack}}}+{{{Defense}}}+ | |||
{{{SpAtk}}}+{{{SpDef}}}+{{{Speed}}} | |||
}} | |||
</span></td> | |||
<td class="bar"></td> | |||
<td class="range"></td> | |||
<td class="range"></td> | |||
</tr> | |||
</tbody> | |||
</table> | |||
</div></includeonly> | |||
<noinclude> | |||
<pre>{{StatTable | |||
|HP=80 |Attack=82 |Defense=83 |SpAtk=100 |SpDef=100 |Speed=80 | |||
}}</pre> | |||
[[Category:Template documentation]] | |||
</noinclude> | |||
< | |||
Revision as of 06:25, 19 May 2025
{{StatTable
|HP=80 |Attack=82 |Defense=83 |SpAtk=100 |SpDef=100 |Speed=80
}}