feat: add prestige system and skill upgrades with comprehensive documentation
Build and Publish Mana Loop Docker Image / build-and-publish (push) Failing after 5m57s
Build and Publish Mana Loop Docker Image / build-and-publish (push) Failing after 5m57s
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
# Context: upgrade-effects.ts
|
||||
|
||||
- Total line count: 191
|
||||
|
||||
## Top-Level Exports
|
||||
|
||||
1. **`getActiveUpgrades`** (lines ~28-51)
|
||||
- Returns all selected upgrades with full effect definitions from the skill upgrades record
|
||||
- Builds cache of upgrade definitions on first access, iterates over SKILL_EVOLUTION_PATHS
|
||||
|
||||
2. **`computeEffects`** (lines ~54-188)
|
||||
- Computes all active effects from selected upgrades into a ComputedEffects object
|
||||
- Applies multipliers, bonuses, and special effects from upgrades; handles DEEP_UNDERSTANDING and MANA_THRESHOLD
|
||||
|
||||
3. **`upgradeDefinitionsById`** (line ~15)
|
||||
- Cache Map for quick lookup of upgrade definitions by ID
|
||||
|
||||
4. **`buildUpgradeCache`** (lines ~18-25)
|
||||
- Initializes the upgrade definition cache from SKILL_EVOLUTION_PATHS
|
||||
|
||||
## Imports
|
||||
|
||||
- `SkillUpgradeChoice`, `SkillUpgradeEffect` from './types'
|
||||
- `getUpgradesForSkillAtMilestone`, `SKILL_EVOLUTION_PATHS` from './skill-evolution'
|
||||
- `ActiveUpgradeEffect`, `ComputedEffects` from './upgrade-effects.types'
|
||||
- `SPECIAL_EFFECTS`, `hasSpecial` from './special-effects'
|
||||
- `computeDynamicRegen`, `computeDynamicClickMana`, `computeDynamicDamage` from './dynamic-compute'
|
||||
|
||||
## Assessment
|
||||
|
||||
This file is already **191 lines** (well under 400). No refactoring needed. The exports are cleanly separated - `getActiveUpgrades` handles data gathering, `computeEffects` handles computation. The module is focused on a single concern (upgrade effects) and is not a candidate for splitting.
|
||||
Reference in New Issue
Block a user