Template:CargoDamage: Difference between revisions

From Official Barotrauma Wiki
Jump to: navigation, search
No edit summary
No edit summary
Line 5: Line 5:
! Max Hits/s
! Max Hits/s
! Armor Penetration
! Armor Penetration
! [[Fabricator]] Materials
! [[Fabricator]] Materials{{#cargo_query:
{{#cargo_query:
tables = Items
tables = Items
| fields = Items.name, Items.icon, Items.afflictions, Items.hitspersecond, Items.penetration, Items.fabricatormaterials
| fields = Items.name, Items.icon, Items.afflictions, Items.hitspersecond, Items.penetration, Items.fabricatormaterials

Revision as of 14:39, 14 November 2021

Documentation

This template is used to display a damage table that reads data from the Items cargo table. Items called this way must have their data set in their respective infoboxes, on their respective pages, for the data to be stored in the cargo table.

Sub Templates

Syntax

{{CargoDamage|tabletype=<melee> or <sub>|item 1|item 2|item 3|item 4|item 5|item 6|width = <custom width, default 50>}}

Important note: unlike most templates, parameters cannot have spaces and/or newlines between them and the separator pipes. So the following won't work, for example: {{CargoDamage| item 1 | item 2 }}

Example

{{CargoDamage|tabletype=melee|Diving Knife|Hardened Diving Knife|Dementonite Diving Knife|Europan Handshake}}

Gives:

Item Afflictions Max Hits/s Armor Penetration Fabricator Materials
Error: No field named "hitspersecond" found for the database table "Items".
|}