Calculate DPS for upgrade recommendations

This commit is contained in:
Jan Bader
2026-06-16 15:06:03 +02:00
parent d4f3d6609b
commit 690faf6c57
3 changed files with 118 additions and 10 deletions
+28 -3
View File
@@ -39,9 +39,10 @@ Effects start at `1%` and can be upgraded up to their cap.
The app lets you enter the current state of all equipment and then recommends:
1. **What to increase next**
- Prioritizes effects by weighted strategic value.
- Prioritizes effects by actual DPS gain for the selected combat style.
- Accounts for each effect's remaining room to grow before cap.
- Highlights high-value underleveled effects.
- Shows the DPS gain from the next `+1%` and from upgrading to cap.
- Crit damage has no DPS value until crit chance is above `0%`.
2. **What is best to sacrifice instead**
- Scores every equipped piece from its base stat and effects.
@@ -51,7 +52,31 @@ The app lets you enter the current state of all equipment and then recommends:
3. **Overall build summary**
- Totals base damage and health.
- Totals effect percentages across all items, mount, and pets.
- Shows a simple offensive and defensive score to compare save slots.
- Shows calculated DPS and a defensive score to compare save slots.
## DPS model
The app calculates DPS from entered base damage and offensive effects:
```text
DPS = base damage
* (1 + damage%)
* (1 + selected style damage%)
* (1 + attack speed%)
* (1 + double chance%)
* (1 + crit chance% * crit damage%)
* skill cooldown multiplier, only for Skill style
```
The selected combat style controls which specialized damage bonus is used:
- Melee uses melee damage.
- Ranged uses ranged damage.
- Skill uses skill damage and skill cooldown reduction.
All additive bonuses are evaluated against the current total. For example, if the build already has `+100% melee damage`, adding another `+50% melee damage` increases the melee multiplier from `2.0x` to `2.5x`, which is an actual `+25%` DPS increase rather than `+50%`.
Each item effect row displays its actual current DPS contribution and the marginal DPS gain from the next `+1%` upgrade.
## Strategy profile