Log inGet started
Package

roll.module

README.md

gearStatsKit.roll

Pure item maths, no engine state. An id gk-<base>-r<rarity>-l<level>-s<seed>[-t<theme>] encodes the whole roll, and gu-<unique>[-t<theme>] names a fixed-stat unique or set piece; describe(id) rebuilds the same item anywhere from it and the catalogue. roll(opts) makes an id, rollDrop(opts) rolls a drop from a tier table, compare(newId, oldId) lists stat deltas, the power delta and an upgrade / downgrade / sidegrade verdict (a power change within 3% is a sidegrade). Item level scales flat implicit stats by 10% a level, percent implicit stats by 2% a level and each affix by its perLevel; the rarity's quality multiplier (common 1.0 to legendary 1.65, with a ±8% roll) applies to all of it.