Template:Offense/doc: Difference between revisions

From Archaelund Wiki
No edit summary
No edit summary
Line 11: Line 11:
<table class="wikitable>
<table class="wikitable>
<tr><th>Format</th><th>Description</th><th>Input</th><th>Example output</th></tr>
<tr><th>Format</th><th>Description</th><th>Input</th><th>Example output</th></tr>
<tr><td>1...7</td><td>Extracts the value of the ith entry (i = 1...7) in the offense property input.</td><td>vector of 7 comma-separated numbers, representing offense values (e.g. "3,8,0,2,1,50,10")</td><td>{{Offense|3,8,0,0,0,50,10|1}}</td></tr>
<tr><td>1...9</td><td>Extracts the value of the ith entry (i = 1...9) in the offense property input.</td><td>vector of 9 comma-separated numbers, representing offense values (e.g. "3,8,0,1,4,1,50,10,1")</td><td>{{Offense|3,8,0,1,4,1,50,10,1|1}}</td></tr>
<tr><td>d1...d7</td><td>Extracts the value of the ith entry (i = 1...7) in the offense property input and formats it as a bonus/malus using [[Template:Difference]].</td><td>vector of 7 comma-separated numbers, representing offense values (e.g. "3,8,0,2,1,50,10")</td><td>{{Offense|3,8,0,0,0,50,10|d1}}</td></tr>
<tr><td>d1...d9</td><td>Extracts the value of the ith entry (i = 1...9) in the offense property input and formats it as a bonus/malus using [[Template:Difference]].</td><td>vector of 9 comma-separated numbers, representing offense values (e.g. "3,8,0,1,4,1,50,10,1")</td><td>{{Offense|3,8,0,1,4,1,50,10,1|d1}}</td></tr>
<tr><td>Damage</td><td>Displays consolidated damage information, including element icons.</td><td>vector of 7 comma-separated numbers, representing offense values (e.g. "3,8,0,2,1,50,10")</td><td>{{Offense|3,8,0,2,1,50,10|Damage}}</td></tr>
<tr><td>Damage</td><td>Displays consolidated damage information, including element icons.</td><td>vector of 9 comma-separated numbers, representing offense values (e.g. "3,8,0,1,4,1,50,10,1")</td><td>{{Offense|3,8,0,1,4,1,50,10,1|Damage}}</td></tr>
</table>
</table>
In the above-mentioned vector of 7 comma-separated numbers, each position/index corresponds to a specific offense property. See the subsequent list for details.
In the above-mentioned vector of 9 comma-separated numbers, each position/index corresponds to a specific offense property. See the subsequent list for details.


== Offense property names ==
== Offense property names ==
Line 27: Line 27:
<tr><td>6</td><td>{{Offense/names|6}}</td></tr>
<tr><td>6</td><td>{{Offense/names|6}}</td></tr>
<tr><td>7</td><td>{{Offense/names|7}}</td></tr>
<tr><td>7</td><td>{{Offense/names|7}}</td></tr>
</table>
<tr><td>8</td><td>{{Offense/names|8}}</td></tr>
<tr><td>9</td><td>{{Offense/names|9}}</td></tr></table>
To extract the individual offense property names use the following syntax:
To extract the individual offense property names use the following syntax:
<pre>
<pre>
Line 42: Line 43:
<tr><td>66</td><td>{{Offense/names|66}}</td></tr>
<tr><td>66</td><td>{{Offense/names|66}}</td></tr>
<tr><td>77</td><td>{{Offense/names|77}}</td></tr>
<tr><td>77</td><td>{{Offense/names|77}}</td></tr>
<tr><td>88</td><td>{{Offense/names|88}}</td></tr>
<tr><td>99</td><td>{{Offense/names|99}}</td></tr>
</table>
</table>

Revision as of 16:08, 20 November 2023

Description

This template generates various output formats from raw offense property input.

Usage

{{Offense|<offense property input>|<format>}}

Make sure that <offense property input> is formatted correctly according to the rules given below, otherwise error messages may be generated.

Format options

FormatDescriptionInputExample output
1...9Extracts the value of the ith entry (i = 1...9) in the offense property input.vector of 9 comma-separated numbers, representing offense values (e.g. "3,8,0,1,4,1,50,10,1")3
d1...d9Extracts the value of the ith entry (i = 1...9) in the offense property input and formats it as a bonus/malus using Template:Difference.vector of 9 comma-separated numbers, representing offense values (e.g. "3,8,0,1,4,1,50,10,1")+3
DamageDisplays consolidated damage information, including element icons.vector of 9 comma-separated numbers, representing offense values (e.g. "3,8,0,1,4,1,50,10,1")3−8 + Fire.png 1−4

In the above-mentioned vector of 9 comma-separated numbers, each position/index corresponds to a specific offense property. See the subsequent list for details.

Offense property names

IndexName
1Min. Damage
2Max. Damage
3Damage Type
4Min. Extra Damage
5Max. Extra Damage
6Extra Damage Type
7Accuracy
8Critical Chance
9Armor Piercing

To extract the individual offense property names use the following syntax:

{{Offense/names|<offense property index>}}

Abbreviated names can be produced for each offense property by using specific double indices:

IndexName
11Damage
22Damage
33Damage
44Damage
55Damage
66Damage
77Acc.
88Crit.
99Arm. Pierc.