Template:Penetrate

From Terraria Wiki
Jump to navigation Jump to search
This template is i18n-ready, which means it is easy to localize for different languages. Please see I18n & l10n for templates to learn more.
See Template:Penetrate/l10n for the localization of this template.
Template-info.svg Documentation The documentation below is transcluded from Template:Penetrate/doc. (edit | history)

Used for displaying the penetrate (pierce) count of a projectile.

Usage

{{ penetrate | auto = <projectile ID> | <penetrate count> | penalty/p = <penalty> (optional) | name = <projectile name> (optional) | article = <custom article> (optional) }}

auto

ID of the projectile. Automatically fills the penetrate count stat and projectile name. Can be omitted or overridden via the first unnamed parameter/$name.

First unnamed parameter

The total number of targets the projectile can hit, which is the same as the projectile's penetrate parameter in the source code. Input -1 for infinite pierce. $auto sets this automatically.

Note that the "pierce count" is "penetrate - 1", e.g. penetrate = 5 means that the projectile can pierce up to 4 targets and dissipates upon hitting the fifth.

penalty or p

The pierce damage penalty of the projectile, with the percentage sign (the value will be formatted via {{percent}}).

name

The name of the projectile. $auto sets this automatically. Defaults to "projectile" if omitted or set to \0 (e.g. to force the default even if $auto is used).

article

Custom article to override the default "The".

Examples

Code Result
{{penetrate|2}} The projectile can pierce up to 1 target, hitting a total of 2 targets.
{{penetrate|-1}} The projectile can pierce an infinite number of targets.
{{penetrate|5|p=15%}} The projectile can pierce up to 4 targets, hitting a total of 5 targets. The damage of the projectile decreases by 15% for each target it pierces.
{{penetrate|5|name=FOO}} The FOO can pierce up to 4 targets, hitting a total of 5 targets.
{{penetrate|-1|p=15%|name=bar}} The bar can pierce an infinite number of targets. The damage of the bar decreases by 15% for each target it pierces.
{{penetrate|auto=242}} The High Velocity Bullet can pierce up to 2 targets, hitting a total of 3 targets.
{{penetrate|auto=242|p=15%}} The High Velocity Bullet can pierce up to 2 targets, hitting a total of 3 targets. The damage of the High Velocity Bullet decreases by 15% for each target it pierces.
{{penetrate|auto=242|p=15%|article=This}} This High Velocity Bullet can pierce up to 2 targets, hitting a total of 3 targets. The damage of this High Velocity Bullet decreases by 15% for each target it pierces.
{{penetrate|auto=242|p=15%|name=\0}} The projectile can pierce up to 2 targets, hitting a total of 3 targets. The damage of the projectile decreases by 15% for each target it pierces.
{{penetrate}} The projectile can pierce up to -1 target, hitting a total of targets.