Release Healer Man 0.1.4

This commit is contained in:
phenom committed 2026-08-18 12:06:04 -04:00
1 parent 5bb170039a
commit f4c9cf356c
63 files changed
+2694 -81

No files matched your search

+33
View File
@@ -5,6 +5,7 @@ import {
createLocalAccount,
createOfflineSession,
listCharacters,
loadCombatPresentationSettings,
loginLocalAccount,
updateCharacterActionBindings,
updateCharacterEquipment,
@@ -12,9 +13,11 @@ import {
updateCharacterManastormProgress,
updateCharacterProgression,
updateCharacterSettings,
updateCombatPresentationSettings,
type StorageLike,
} from "./accountRepository";
import { DEFAULT_GAMEPLAY_SETTINGS } from "../game/combatStore";
import { DEFAULT_COMBAT_PRESENTATION_SETTINGS } from "../game/combatPresentation";
import { EMPTY_ITEM_STATS } from "../game/itemStats";
import {
MANASTORM_PROGRESS_VERSION,
@@ -124,6 +127,36 @@ describe("local profile repository", () => {
});
});
it("migrates v1/v2 databases and stores combat presentation settings by owner", async () => {
for (const version of [1, 2]) {
const storage = new MemoryStorage();
storage.setItem(PROFILE_STORAGE_KEYS.database, JSON.stringify({
version,
accounts: [],
rosters: { "offline-roster": [] },
}));
expect(loadCombatPresentationSettings("offline-roster", storage))
.toEqual(DEFAULT_COMBAT_PRESENTATION_SETTINGS);
expect(JSON.parse(storage.getItem(PROFILE_STORAGE_KEYS.database)!).version).toBe(3);
}
const storage = new MemoryStorage();
const firstOwner = (await createLocalAccount("EffectsOne", "eight-plus", storage)).session!.ownerId;
const secondOwner = (await createLocalAccount("EffectsTwo", "eight-plus", storage)).session!.ownerId;
const customized = updateCombatPresentationSettings(firstOwner, {
...DEFAULT_COMBAT_PRESENTATION_SETTINGS,
vfxQuality: "low",
vfxEnabled: { player: true, party: false, enemy: true },
audioEnabled: { player: true, party: true, enemy: false },
audioVolume: { player: 0.75, party: 0.4, enemy: 0.2 },
}, storage);
expect(loadCombatPresentationSettings(firstOwner, storage)).toEqual(customized);
expect(loadCombatPresentationSettings(secondOwner, storage)).toEqual(DEFAULT_COMBAT_PRESENTATION_SETTINGS);
expect(loadCombatPresentationSettings(createOfflineSession().ownerId, storage))
.toEqual(DEFAULT_COMBAT_PRESENTATION_SETTINGS);
});
it("migrates custom-class profiles into the CoA category", () => {
const storage = new MemoryStorage();
const offline = createOfflineSession();