forked from phenom/healer-man
Release Healer Man 0.1.14
This commit is contained in:
1 parent
67d7a8ebe7
commit
7b41b102fa
147 files changed
+169892
-1342
No files matched your search
@@ -1,4 +1,5 @@
|
||||
import { afterEach, beforeEach, describe, expect, it } from "vitest";
|
||||
import { PLAYER_AGGRO_ID } from "./aggro";
|
||||
import {
|
||||
deterministicEnemyCooldown,
|
||||
useCombatStore,
|
||||
@@ -171,6 +172,42 @@ describe("server-backed enemy ability runtime", () => {
|
||||
expect(summonIds.every((id) => getMobPosition(id) === null)).toBe(true);
|
||||
});
|
||||
|
||||
it("applies a modular target aura as a dispellable player debuff", () => {
|
||||
useCombatStore.getState().registerMob("runewaker-debuffer", {
|
||||
name: "RuneWaker Debuffer",
|
||||
maxHealth: 1_000,
|
||||
attacks: [{
|
||||
id: "conductivity",
|
||||
name: "Conductivity",
|
||||
delivery: "projectile",
|
||||
target: "primary",
|
||||
school: "arcane",
|
||||
animation: "cast",
|
||||
castTimeMs: 1_000,
|
||||
range: 20,
|
||||
cooldownMs: 10_000,
|
||||
initialCooldownMs: [0, 0],
|
||||
repeatCooldownMs: [10_000, 10_000],
|
||||
damageMultiplier: 0,
|
||||
effect: { kind: "target-aura", aura: "conductivity", durationMs: 6_000 },
|
||||
}],
|
||||
});
|
||||
setMobPosition("runewaker-debuffer", [2, 0, 0]);
|
||||
useCombatStore.getState().damageMob("runewaker-debuffer", 1, 1_000);
|
||||
useCombatStore.getState().advanceMobCombat(1_000, [0, 0, 0]);
|
||||
useCombatStore.getState().advanceMobCombat(2_000, [0, 0, 0]);
|
||||
|
||||
expect(useCombatStore.getState().auras).toContainEqual(expect.objectContaining({
|
||||
sourceId: "runewaker-debuffer",
|
||||
targetId: PLAYER_AGGRO_ID,
|
||||
expiresAt: 8_000,
|
||||
definition: expect.objectContaining({
|
||||
disposition: "debuff",
|
||||
dispelCategory: "magic",
|
||||
}),
|
||||
}));
|
||||
});
|
||||
|
||||
it("honors encounter-state conditions before selecting an ability", () => {
|
||||
useWailingEncounterStore.getState().reset();
|
||||
useCombatStore.getState().registerMob("event-caster", {
|
||||
|
||||
Reference in new issue
Block a user