Template:SetProp/doc
From Salem Wiki
< Template:SetProp
Revision as of 15:36, 28 June 2012 by ©TriMoon™ (talk | contribs) (→Supported propname's: added new propnames)
Description
- This is a wrapper-template that calls {{SetProp/single}} to automatically set property values.
- It has a fixed-set of properties it supports, and can be expanded when needed in code...
- Some properties are fit to assign multiple values to, using a sep, but those of type Boolean are obviously not...
- Supported properties of type Boolean will always automatically be set to "false" as default when not explicitly set.
Syntax
- Type the below code somewhere on a page:
{{SetProp |propname=propvalues |propname=propvalues |... }}
- It supports this optional named-parameter:
- sep
- The default separator used in the propvalues to separate single-values from each other.
- It defaults to a comma ','
- sep
Supported propname's
- It currently supports these multi-value properties:
- IsinGameMenu ⇐ Default separator is a ^ when no over-ride is used in sep, be careful this property can use a comma in its valid value!
- RequiresTech
- RequiresObj
- RepairedWith
- It currently supports these single-value properties:
- IsGameMenu (Boolean)
- Has icon (Page)
- Only supply the filename, it will automatically prepend the final property-value with
Image:
- When not used, it will auto-set this property to
Image:{{SUBPAGENAME}} icon.png
- Only supply the filename, it will automatically prepend the final property-value with
- Has fullview (Page)
- Only supply the filename, it will automatically prepend the final property-value with
Image:
- Only supply the filename, it will automatically prepend the final property-value with
- IsLiftable (Boolean)
- IsLiftableWhenEmpty (Boolean)
- Will auto-set IsLiftable='true' when used with any value, so only use it to assign a true!
- HP (Number)
- Soak (Number)
Examples
See the example(s) in the documentation of {{SetProp/single}}, this template just passes known properties with their values to it.