Template:Sell expr/doc

This template can be used to handle elaborate expressions in conjunction with item sell values. The sell values are generated using iteminfo, hence they are dynamic and are adjusted accordingly should they be altered in a future Terraria update.

It aims at simplifying the convoluted syntax that is required for displaying sell value expressions:  can be shortened to   using this template.

Usage
Name of an item whose sell value is to be inserted at that part of the expression. Can be empty.
 * 1st, 3rd, 5th, 7th, ... nth unnamed parameter

Operators, constants, etc. – valid  syntax. Can be empty.
 * 2nd, 4th, 6th, 8th, ... (n+1)-th unnamed parameter

Suppress the coin wrapping and instead display the numerical value, e.g. for use in other expressions.
 * raw

Concept
Example: Multiply the sum of the sell values of 3 Pixie Dust and 1 Crystal Shard by 5 and add the sell value of 7 Souls of Light.

Think of writing the expression normally:

For this template, simply replace the  parts with  :

Note that in this case, the first unnamed parameter is not an item name. Therefore, add an empty parameter to fix that:

Result:

Proof: