Skip to content

Item Weight

Nibrock edited this page Aug 24, 2022 · 1 revision

How It Works

The Item Weight system for rarity works in the following way. All of the weights are added up together and then a die with that many sides is rolled. Whichever rarity the number is directly under is which one is chosen.

For example, if you have a common weight of 100 and a legendary weight of 5, a 105-side die is rolled. If the roll is anywhere between 5 and 105, common will be the rarity given. If it is below 5 then legendary will be selected.

Configuring Weights

All of the default caskets can be reconfigured to be more or less common.

You can also add custom caskets, with fully configurable weights.

Note: The more caskets you add, the more the pre-existing chances will change. For example, if you added a casket with a weight of 190, the chance to catch ANY of the default caskets will be decreased to 50%, as opposed to 100%. See calculating rarity above.

Due to the way it works, it is recommended that none of the weights are the same. The system will still function but it will likely cause some inconsistencies, and not function the way you intended.

Calculating Rarity

Note: The config ONLY accepts Weight inputs for Rarity. You can theoretically input weight values that in total, add up to 100, and this will display the rarity in a rough percentage form, though this only allows for chances down to 1%.

If it's easier to preview your rarity values in percentage form, you can calculate these percentages using the following formula.

$$ x = {Item Weight \over Sum Of All Item Weights} $$

For example, if you take the values from the default Rarity config,

You would add the weights of all the Rarities

(100+60+30+5) = 195

And then divide the weight you wish to see in percentage form by the result

(100/195) = 0.5128 (Which is 51.28%)

Multiply this by 100 to view the value more easily. (0.5128 * 100) = 51.28

Here are the calculated default chances of a specific casket being caught.

Note: This is the chance of a specific casket being caught WHEN a casket is caught, not everytime a player attempts to fish.