Template:Sandbox/MoonOverMira/class attributes/doc: Difference between revisions
Jump to navigation
Jump to search
MoonOverMira (talk | contribs) (Created page with "{{Documentation subpage}} ==Usage== {{tl|{{BASEPAGENAME}}}} ===Examples=== {{Class attributes |cols=str,dex,int |show_total=true }} {{Class attributes |cols=str }} {{Documentation categories| <!-- Categories and interwikis go here. --> Category:Templates }}") |
No edit summary |
||
(6 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{Documentation subpage}} | {{Documentation subpage}} | ||
{{Lua|Module:Sandbox/MoonOverMira/class attributes}} | |||
==Overview== | |||
Creates a table of classes and their base attributes. This data comes from [[Module:Game]], though similar information can be found in [[Special:CargoTables/character_classes]]. | |||
== | ==Parameters== | ||
The only required parameter is cols. | |||
===Examples=== | {| class="wikitable" | ||
{{ | ! Parameter | ||
! Value | |||
! Description | |||
|- | |||
| cols | |||
| str | |||
| A comma-separated list of the attributes to include as columns. Valid attributes are <code>str</code>, <code>dex</code>, and <code>int</code>. | |||
|- | |||
| show_total | |||
| bool | |||
| Whether to include the total of the attributes as a column at the end. | |||
|- | |||
| sort_col | |||
| str | |||
| An attribute to sort the table by. Only one of the valid attributes should be given. | |||
|- | |||
| reverse_sort | |||
| bool | |||
| Whether to sort the attribute column given by <code>sort_col</code> from greatest to least instead of from least to greatest. | |||
|} | |||
==Examples== | |||
{| class="wikitable" | |||
! Description | |||
! Usage | |||
! Result | |||
|- | |||
|All attributes and a total | |||
|<pre> | |||
{{Sandbox/MoonOverMira/class attributes | |||
|cols=str,dex,int | |cols=str,dex,int | ||
|show_total=true | |show_total=true | ||
}} | }} | ||
</pre> | |||
{{ | |{{Sandbox/MoonOverMira/class attributes | ||
|cols=str,dex,int | |||
|show_total=true | |||
}} | |||
|- | |||
|A single attribute, sorted from greatest to least | |||
|<pre> | |||
{{Sandbox/MoonOverMira/class attributes | |||
|cols=str | |||
|sort_col=str | |||
|reverse_sort=true | |||
}} | |||
</pre> | |||
|{{Sandbox/MoonOverMira/class attributes | |||
|cols=str | |cols=str | ||
|sort_col=str | |||
|reverse_sort=true | |||
}} | }} | ||
|} | |||
{{Documentation categories| | {{Documentation categories| | ||
<!-- Categories and interwikis go here. --> | <!-- Categories and interwikis go here. --> | ||
}} | }} |
Latest revision as of 20:51, 9 March 2023
This subpage provides documentation for Template:Sandbox/MoonOverMira/class attributes.
Overview
Creates a table of classes and their base attributes. This data comes from Module:Game, though similar information can be found in Special:CargoTables/character_classes.
Parameters
The only required parameter is cols.
Parameter | Value | Description |
---|---|---|
cols | str | A comma-separated list of the attributes to include as columns. Valid attributes are str , dex , and int .
|
show_total | bool | Whether to include the total of the attributes as a column at the end. |
sort_col | str | An attribute to sort the table by. Only one of the valid attributes should be given. |
reverse_sort | bool | Whether to sort the attribute column given by sort_col from greatest to least instead of from least to greatest.
|
Examples
Description | Usage | Result | ||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
All attributes and a total | {{Sandbox/MoonOverMira/class attributes |cols=str,dex,int |show_total=true }} |
| ||||||||||||||||||||||||||||||||||||||||
A single attribute, sorted from greatest to least | {{Sandbox/MoonOverMira/class attributes |cols=str |sort_col=str |reverse_sort=true }} |
|