fix(store/computed): remove banned 'life' element from getFloorElement()
Build and Publish Mana Loop Docker Image / build-and-publish (push) Failing after 34s
Build and Publish Mana Loop Docker Image / build-and-publish (push) Failing after 34s
- Removed local FLOOR_ELEM_CYCLE array containing banned 'life' element - Now imports FLOOR_ELEM_CYCLE from ../constants (which already excludes 'life') - Updated getFloorElement() to use imported constant with dynamic length
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
// ─── Computed Stats Functions ─────────────────────────────────────────────────
|
// ─── Computed Stats Functions ─────────────────────────────────────────────────
|
||||||
|
|
||||||
import type { GameState } from '../types';
|
import type { GameState } from '../types';
|
||||||
import { ELEMENTS, GUARDIANS, SPELLS_DEF, SKILLS_DEF, PRESTIGE_DEF, ELEMENT_OPPOSITES } from '../constants';
|
import { ELEMENTS, GUARDIANS, SPELLS_DEF, SKILLS_DEF, PRESTIGE_DEF, ELEMENT_OPPOSITES, FLOOR_ELEM_CYCLE } from '../constants';
|
||||||
import { computeEffects } from '../upgrade-effects';
|
import { computeEffects } from '../upgrade-effects';
|
||||||
import type { ComputedEffects } from '../upgrade-effects.types';
|
import type { ComputedEffects } from '../upgrade-effects.types';
|
||||||
import type { UnifiedEffects } from '../effects';
|
import type { UnifiedEffects } from '../effects';
|
||||||
@@ -284,8 +284,7 @@ export function getFloorMaxHP(floor: number): number {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function getFloorElement(floor: number): string {
|
export function getFloorElement(floor: number): string {
|
||||||
const FLOOR_ELEM_CYCLE = ["fire", "water", "air", "earth", "light", "dark", "life", "death"];
|
return FLOOR_ELEM_CYCLE[(floor - 1) % FLOOR_ELEM_CYCLE.length];
|
||||||
return FLOOR_ELEM_CYCLE[(floor - 1) % 8];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Formatting utilities
|
// Formatting utilities
|
||||||
|
|||||||
Reference in New Issue
Block a user