Loot Rarity is a JS library for Node and the browser that allows to get the rarity level of Loot items based on their number of occurrences. There are six of these levels, from Common to Mythic (you can find the distribution numbers in the README).
It can:
- Transform an image to add rarity levels to it.
- Give the rarity level of any item.
- Give the color rarity levels.
- Give the description of rarity levels.
- Use a specific color for your favourite items.
It accepts anything you can think of:
- A list of items.
- A Loot image as a data URI string.
- A Loot image as an SVG string.
- A Loot image as a URL.
- A Loot metadata as a data URI string.
- A Loot metadata as a URL.
- All of the above works for LootLoose too.
It’s used by:
- 0xinventory.app
- Divine Robes
- The Grand Exchange
- Loot World
- The #sales channel bot
- The Loot Rarity for OpenSea bookmarklet
- LootLoose
- Your Loot project… just kidding… unless…?
Links:
License:
MIT, but I pronounce it “Absolutely. You can do whatever you want”-licensed.
Let me know if you have any feedback, any question, or any cool feature idea!