No edit summary
No edit summary
 
Line 1: Line 1:
Generic template to render randomized sequences of items.
Generic template to render an indiscriminately randomized sequence of items.


== Usage ==
== Usage ==
This template allows editors to render an indiscriminately randomized sequence of items. Each invocation of the template produces its own independent order.
Example:
<pre>
<pre>
{{RandomItemSequence
{{RandomItemSequence
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
| tooltip = Apricorn Sprouts
| tooltip = Apricorn Sprouts
| link = [[Apricorn Sprout]]
}}
{{RandomItemSequence
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
| tooltip = Example items
| link = [[Apricorn Sprout]]
}}
{{RandomItemSequence
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
| tooltip = Example items
| link = [[Apricorn Sprout]]
| link = [[Apricorn Sprout]]
}}
}}
</pre>
</pre>
Produces:
Produces:
<div style="display:flex">
{{RandomItemSequence
{{RandomItemSequence
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
Line 30: Line 16:
| link = [[Apricorn Sprout]]
| link = [[Apricorn Sprout]]
}}
}}
{{RandomItemSequence
</div>
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
| tooltip = Example items
| link = [[Apricorn Sprout]]
}}
{{RandomItemSequence
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
| tooltip = Example items
| link = [[Apricorn Sprout]]
}}
 
== Parameters ==
== Parameters ==
* '''items''' (required) – Semicolon-separated list of item names. <ref>See [[Template:ItemSlot]]</ref>
* '''items''' (required) – Semicolon-separated list of item names. <ref>See [[Template:ItemSlot]]</ref>
Line 48: Line 24:


== Notes ==
== Notes ==
* Multiple invocations on the same page will produce independent random orders unless a numeric `reseed` is provided
* Multiple invocations on the same template will produce independent random orders unless a numeric `reseed` is provided.
* This template can be used directly for deterministic sequences or as a building block in wrapper templates for predefined item groups.

Latest revision as of 21:06, 28 December 2025

Generic template to render an indiscriminately randomized sequence of items.

Usage

{{RandomItemSequence
| items = Red Apricorn Sprout; Blue Apricorn Sprout; Pink Apricorn Sprout; Yellow Apricorn Sprout; Green Apricorn Sprout; Black Apricorn Sprout; White Apricorn Sprout
| tooltip = Apricorn Sprouts
| link = [[Apricorn Sprout]]
}}

Produces:


Blue Apricorn Sprout.pngRed Apricorn Sprout.pngPink Apricorn Sprout.pngWhite Apricorn Sprout.pngYellow Apricorn Sprout.pngGreen Apricorn Sprout.pngBlack Apricorn Sprout.png
Apricorn Sprouts



Parameters

  • items (required) – Semicolon-separated list of item names. [1]
  • tooltip (optional) – Text displayed when hovering over the item sequence. Defaults to the first item if omitted. [2]
  • link (optional) – Page to link to when the item sequence is clicked. [3]
  • reseed (optional) – Numeric value used to explicitly seed the random number generator. If provided, the same seed will produce the same item sequence every time.

Notes

  • Multiple invocations on the same template will produce independent random orders unless a numeric `reseed` is provided.