about summary refs log tree commit diff
path: root/dropcalc/dropcalc-notes
diff options
context:
space:
mode:
Diffstat (limited to 'dropcalc/dropcalc-notes')
-rw-r--r--dropcalc/dropcalc-notes61
1 files changed, 61 insertions, 0 deletions
diff --git a/dropcalc/dropcalc-notes b/dropcalc/dropcalc-notes
new file mode 100644
index 0000000..b334e43
--- /dev/null
+++ b/dropcalc/dropcalc-notes
@@ -0,0 +1,61 @@
+TreasureClassEx.txt
+tab-separated
+Picks
+Unique, Set, Rare, Magic
+NoDrop
+Item{1-10} : can be a TC name, Weapons/Armor/Misc/Gems code, UniqueItems index, maybe even SetItems index
+Prob{1-10}
+
+group/level can upgrade tc but that's skippable for now until we need to deal with monsters
+
+
+
+for generic TCs:
+read Weapons.txt, Armor.txt code, rarity
+use name for now, deal with namestr & string tbls later
+
+
+
+NoDrop adjustment:
+fundamentally it just retries once per (close, partied) player until an item is hit.
+far and/or unpartied players count half
+
+
+item quality:
+ItemRatio.txt
+Unique, UniqueDivisor, UniqueMin... etc
+
+chance = 128 * (Unique - (ilvl-qlvl)/Divisor)
+eMF = (MF * factor) / (MF + Factor) like basically all diminishing returns
+chance = chance * eMF
+cap to minChance
+chance = chance - (chance * tcUnique / 1024)
+
+roll 0 to chance-1, if less than 128 then success
+which means lower "chance" is better
+
+unique is picked with rarity / total rarity of uniques for base that have the right ilvl as expected
+
+game rolls unique - set - rare - magic - superior - normal in order
+
+
+
+affixes the fuckening:
+rares have 2+d4 affixes, 50/50 for each to be prefix or suffix until 3
+crafts have 4 affixes (or 0.4/0.2/0.2/0.2 for 1-4 at ilvl 1), otherwise the same
+generate in order, exclude by group
+
+alvl of item is:
+tmplvl = min(ilvl, 99)
+tmplvl = max(qlvl, tmplvl)
+if magic_level: 
+	alvl = tmplvl + magic_level	
+else if tmplvl < (99 - qlvl/2):
+	alvl = tmplvl - qlvl/2
+else:
+	alvl = 2 * tmplvl - 99
+return min(alvl, 99)
+
+should likely monte carlo simulate crafts rather than try and calculate them
+
+need to fuck around with Itemtypes, MagicPrefix, MagicSuffix to get all the possible affixes