Template:Chance to: Difference between revisions
From Space Station 14 Wiki
(Created page with "{{#ifeq:{{{prob}}}|1|{{1}}}|{{#expr:{{{prob}}}*100}}% chance to {{{1}}}}}") |
(desc) |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{#ifeq:{{{prob}}}|1|{{1}}}|{{#expr:{{{prob}}}*100}}% chance to {{{1}}}}} | <includeonly>{{#ifeq:{{{prob}}}|1|{{{1}}}|{{#expr:{{{prob}}}*100}}% chance to {{{1}}}}}</includeonly><noinclude> | ||
{{documentation}} | |||
[[Category:Templates without specific category]] | |||
<templatedata> | |||
{ | |||
"params": { | |||
"1": { | |||
"label": "What will happen?", | |||
"description": "A chance to what?", | |||
"example": "blow up", | |||
"type": "string", | |||
"required": true | |||
}, | |||
"prob": { | |||
"label": "Probability", | |||
"description": "A chance of something to happen, from 0 to 1.", | |||
"example": "0.3", | |||
"type": "number", | |||
"required": true | |||
} | |||
}, | |||
"description": "Describes a chance of something to happen using percentages.", | |||
"paramOrder": [ | |||
"1", | |||
"prob" | |||
] | |||
} | |||
</templatedata> | |||
</noinclude> |
Latest revision as of 14:35, 24 June 2024
{{Chance to|prob=.3|blow up}}
→ 30% chance to blow up{{Chance to|prob=1|blow up}}
→ blow up
Describes a chance of something to happen using percentages.
Parameter | Description | Type | Status | |
---|---|---|---|---|
What will happen? | 1 | A chance to what?
| String | required |
Probability | prob | A chance of something to happen, from 0 to 1.
| Number | required |