Template:Drop
From OpenSpell Wiki
Usage
[edit]Use inside a drop table. Automatically colours and labels the rarity based on the odds value.
{| class="wikitable sortable"
! Item !! Amount !! Rarity !! Odds
{{Drop|bones|1|always}}
{{Drop|coins|20|0.15}}
{{Drop|iron sword|1|0.02}}
{{Drop|silver helm|1|0.005}}
|}
Odds parameter
[edit]Either pass a number between 0 and 1, or one of these keywords:
always— guaranteed drop, no odds shown- Any decimal like
0.25,0.05,0.008
The template picks the label and colour automatically:
| Range | Label | Colour |
|---|---|---|
| always | Always | Green |
| ≥ 25% | Always | Green |
| 10–25% | Common | Grey |
| 5–10% | Uncommon | Orange |
| 1–5% | Rare | Red |
| < 1% | Very rare | Purple |