Files
healer-man/src/game/wow335MageImprovedCounterspellRuntime.ts
T
2026-09-30 09:57:13 -04:00

23 lines
788 B
TypeScript

export const WOW335_MAGE_IMPROVED_COUNTERSPELL_TALENT_ID = "talent-88";
export const WOW335_MAGE_IMPROVED_COUNTERSPELL_SILENCE_DURATION_MS = 2_000;
const COUNTERSPELL_COOLDOWN_REDUCTION_MS_BY_RANK = [0, 4_000, 7_000, 10_000] as const;
export function wow335MageImprovedCounterspellCooldownReductionMs(
rank: number,
abilityName: string,
): number {
if (abilityName !== "Counterspell") return 0;
const normalizedRank = Math.max(0, Math.min(3, Math.trunc(rank)));
return COUNTERSPELL_COOLDOWN_REDUCTION_MS_BY_RANK[normalizedRank] ?? 0;
}
export function wow335MageImprovedCounterspellSilenceDurationMs(
rank: number,
abilityName: string,
): number {
return abilityName === "Counterspell" && rank > 0
? WOW335_MAGE_IMPROVED_COUNTERSPELL_SILENCE_DURATION_MS
: 0;
}