[priority: medium] "Steady Hand" prestige upgrade references non-existent durability mechanic #199

Closed
opened 2026-05-29 13:05:08 +02:00 by Anexim · 2 comments
Owner

BUG: Prestige upgrade description mentions durability loss but durability doesn't exist

Bug Summary

The "Steady Hand" prestige upgrade claims "-15% durability loss" but the EquipmentInstance type has no durability mechanic.

Evidence

  • File: src/lib/game/constants/prestige.ts, line 8
    • steadyHand: { name: "Steady Hand", desc: "-15% durability loss", max: 5, cost: 1200 }
  • File: src/lib/game/types/equipment.ts, lines 18-37
    • The active EquipmentInstance interface has NO durability or maxDurability fields
  • durability/maxDurability only exists in the legacy EquipmentDef interface (marked "Legacy EquipmentDef for backward compatibility")
  • No store references durability at all
  • No code applies a "-15% durability loss" effect

Fix Required

Update the description to either:

  1. Describe what steadyHand actually does (if anything)
  2. Implement the durability mechanic it references
  3. Remove the upgrade if unimplemented

Priority

MEDIUM - Misleading upgrade description; blocks informed player decisions

**BUG: Prestige upgrade description mentions durability loss but durability doesn't exist** ### Bug Summary The "Steady Hand" prestige upgrade claims "-15% durability loss" but the `EquipmentInstance` type has no durability mechanic. ### Evidence - **File:** `src/lib/game/constants/prestige.ts`, line 8 - `steadyHand: { name: "Steady Hand", desc: "-15% durability loss", max: 5, cost: 1200 }` - **File:** `src/lib/game/types/equipment.ts`, lines 18-37 - The active `EquipmentInstance` interface has NO `durability` or `maxDurability` fields - `durability`/`maxDurability` only exists in the **legacy** `EquipmentDef` interface (marked "Legacy EquipmentDef for backward compatibility") - No store references durability at all - No code applies a "-15% durability loss" effect ### Fix Required Update the description to either: 1. Describe what `steadyHand` actually does (if anything) 2. Implement the durability mechanic it references 3. Remove the upgrade if unimplemented ### Priority MEDIUM - Misleading upgrade description; blocks informed player decisions
Anexim added the ai:todo label 2026-05-29 13:05:08 +02:00
n8n-gitea was assigned by Anexim 2026-05-29 13:05:08 +02:00
Author
Owner

Starting work on the Steady Hand prestige upgrade bug. Investigating what the upgrade should actually do.

Starting work on the Steady Hand prestige upgrade bug. Investigating what the upgrade should actually do.
Author
Owner

Fixed the Steady Hand prestige upgrade. The description referenced a non-existent durability mechanic. Updated it to provide a real effect:

Changes:

  1. src/lib/game/constants/prestige.ts — Changed description from "-15% durability loss" to "+15% enchantment power"
  2. src/lib/game/effects.ts — Updated computeAllEffects and getUnifiedEffects to accept optional prestigeUpgrades parameter. Steady Hand level now scales enchantmentPowerMultiplier by 1 + level * 0.15
  3. src/lib/game/stores/gameStore.ts — Pass steadyHand level from prestige upgrades to computeEquipmentEffects as enchantmentPowerMultiplier
  4. src/lib/game/stores/gameHooks.ts — Pass prestigeUpgrades through to getUnifiedEffects in useUnifiedEffects, useManaStats, and useCombatStats

The upgrade now actually does something: each level increases enchantment power by 15%, scaling all equipped enchantment bonuses. All 896 tests pass.

Commit: 9e49aa1

Fixed the Steady Hand prestige upgrade. The description referenced a non-existent durability mechanic. Updated it to provide a real effect: Changes: 1. `src/lib/game/constants/prestige.ts` — Changed description from "-15% durability loss" to "+15% enchantment power" 2. `src/lib/game/effects.ts` — Updated `computeAllEffects` and `getUnifiedEffects` to accept optional `prestigeUpgrades` parameter. Steady Hand level now scales `enchantmentPowerMultiplier` by `1 + level * 0.15` 3. `src/lib/game/stores/gameStore.ts` — Pass `steadyHand` level from prestige upgrades to `computeEquipmentEffects` as `enchantmentPowerMultiplier` 4. `src/lib/game/stores/gameHooks.ts` — Pass `prestigeUpgrades` through to `getUnifiedEffects` in `useUnifiedEffects`, `useManaStats`, and `useCombatStats` The upgrade now actually does something: each level increases enchantment power by 15%, scaling all equipped enchantment bonuses. All 896 tests pass. Commit: 9e49aa1
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Anexim/Mana-Loop#199