Rarities can be assigned to cosmetics for use with various methods of unlocking them, or to just display a tag.
They are defined in a rarities section in the `config-cosmetics.yml` file:
```
Rarities:
Default: common
ShowRarity: false # Whether to prepend the cosmetic rarity to icon lore
RarityPrefix: "" # Prefix added before the rarity text in cosmetic icon lore
Definitions:
- Key: common
Weight: 100
Display: "<gray>Common"
- Key: rare
Weight: 25
Display: "<aqua>Rare"
- Key: legendary
Weight: 5
Display: "<gold>Legendary"
```
You can define as many different rarities as you'd like and assign them to any cosmetic with the `Rarity` field. If no rarity is defined, they will default to the configured default rarity.
When using commands, mechanics, or any other methods of giving someone a random rarity, the weight will be used to determine the chance of selecting that item (e.g. a weight of 100 is 100x more likely to be picked than a weight of 1).
Weight can also be overridden on a per-cosmetic basis using the `Weight` field.
Spray Options
-------------
The Sprays section lets you define the stay time (in seconds) and the sound spraying makes. Setting `PersistTime` to `0` will make sprays stay until either a new one is placed or the chunk is unloaded.