1.0.1 • Published 3 years ago

categorized-loot-rarity v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

categorized_loot_rarity

suggestion of new loot NFT rarity

1. Problems of traditional Loot Rarity

  1. The variance of traditional rarity of Loot NFT is not even
  2. Some categories contains nothing
  3. Some items in categories for rarer ones contains more items than categories for more common ones.

2. Suggestion

  • We should adjust the counts threshold for each parts of items.

  • adjusted threshold of item counts each part

partlegendaryepicrarecommon
weaponcount<2count<200count<320other
chestcount<2count<300count<385other
headcount<2count<300count<380other
waistcount<2count<300count<380other
footcount<2count<300count<380other
handcount<2count<300count<380other
neckcount<2count<1800other-
ringcount<2count<1000other-

3. How to use this package

installation

 npm install --save categorized-loot-rarity
  • Or just download and unzip it
  • It doesn't depend anything. These are simple vanilaJs functions

code example

  • sample1
var LootRarity = require('categorized-loot-rarity');
var result = LootRarity.getCategorizedRarities(lootId=50);
console.log(result);
  • output
    {
        weapon: 1,
        chest: 3,
        head: 1,
        waist: 1,
        foot: 3,
        hand: 4,
        neck: 2,
        ring: 2
    }
  • sample2
    var LootRarity = require('categorized-loot-rarity');
    var result = LootRarity.getCategorizedRarities(lootId=50, parts='weapon', value_type='tier');
  • output : common
  • appendix
    • it works to get traditional rarity also for your convenience.
    var LootRarity = require('categorized-loot-rarity');
    console.log(LootRarity.getCategorizedRarities(lootId=50, parts='weapon', value_type='tier')); // 'common'

compare

1.0.1

3 years ago