Open AdamTDewhirst opened 2 years ago
@AdamTDewhirst
is this what other people do ?
Yes, but they don't need to add up to 100.
This is how I did it. Lets say there are 3 rarities. common, uncommon and rare. you want 7777 to be common, 1423 uncommon, and 800 rare in a 10000 nft collection. Although the rarity is based off of 100% value, the layers in a folder don't have to add up to 100. You simpIy have to divide how many you want in a 10000 collection by 100. lets say I have 7 folders with 7 layers. each of the folders have 4 common, 2 uncommon, and 1 rare layers. All four of the common will be #77.77. All of the uncommon #14.23, and rare is #8.
@PeterGRutherford how did you use #14.23 or did you simply use #14 (rounding down)?
I have a use-case where one of the users would like to explicitly state layer item X should have 15 in the 10k collection and layer item Y should have 30. Instead of having a maximum, this is the exact value that he wants, so not sure how to implement this with Rarities as the rarity calculations are completely random (if I understand correctly when I stepped through the code).
@thepeanutgalleryandco I'm using #14.23. I am aware it is random, but I like the idea that it could get as close as it can to 14.23. I am actually using your repository of the art engine @thepeanutgalleryandco. I used rarity_md, then replaced "/_metadata.json" with "/_metadata_with_rarity.json" in update_nft_info.js(line 14), then made my own rarity attribute based on rank inside of update_nft_info.js(lines 18+).
data.forEach((item) => { if (item.rank <= 800) { item.attributes.push({ trait_type: "Rarity", value: "Common", }); }
more of a general question for the group
when working out rarity, my policy is assign each one a percentage out of 100 - having them all add up exactly to 100 percent. they wont all be equal, but it seems logical to me
is this what other people do ? or do you just assign a percentage base on how frequently it could appear? (i.e the chance it could appear, as opposed to the direct percentage value, which is what I'm doing)
any thoughts?