Template:IteratedProbability: Difference between revisions

From Caves of Qud Wiki
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
 
Line 12: Line 12:
Edit the page to see the template text.
Edit the page to see the template text.
</noinclude><includeonly>
</noinclude><includeonly>
{{#switch: {{{type}}} | Roll N times={{#vardefine:result|{{#invoke:IteratedProbability/TemplateIn| tryFor |count={{{count|}}}|probability={{{probability|}}}}}}}There's a {{#var:result}} chance that {{{count}}} rolls at a {{{probability}}} chance will have at least one success.| Roll until probability={{#vardefine:result|{{#invoke:IteratedProbability/TemplateIn| tryUntil |targetprobability={{{targetprobability|}}}|probability={{{probability|}}}}}}}At {{#var:result}} rolls at {{{probability}}}, there's a  {{{targetprobability}}} chance that there will be at least one success.|How did you even do this.}}
{{#switch: {{{type}}} | Roll N times={{#vardefine:result|{{#invoke:IteratedProbability/TemplateIn| tryFor |count={{{count|}}}|probability={{{probability|}}}}}}}There's a {{#var:result}} chance that {{{count}}} rolls at a {{{probability}}} chance will have at least one success.| Roll until probability={{#vardefine:result|{{#invoke:IteratedProbability/TemplateIn| tryUntil |targetprobability={{{targetprobability|}}}|probability={{{probability|}}}}}}}At {{#var:result}} rolls at {{{probability}}}, there's a  {{{targetprobability}}} chance that there will be at least one success.|How did you even do this.}}</includeonly>
 
</includeonly>

Latest revision as of 23:14, 19 August 2019

This is the "IteratedProbability" template. It should be called in the following format:

{{IteratedProbability
|type=
|count=
|probability=
|targetprobability=
}}

Edit the page to see the template text.