@@ -2,7 +2,7 @@ import { readFileSync } from 'node:fs';
|
||||
import { readdirSync } from 'node:fs';
|
||||
import path from 'node:path';
|
||||
|
||||
import { PRESET_CHARACTERS } from '../src/data/characterPresets.ts';
|
||||
import { ROLE_TEMPLATE_CHARACTERS } from '../src/data/characterPresets.ts';
|
||||
import { MONSTER_PRESETS_BY_WORLD } from '../src/data/hostileNpcPresets.ts';
|
||||
import { buildItemCatalogId } from '../src/data/itemCatalog.ts';
|
||||
import { getScenePresetsByWorld } from '../src/data/scenePresets.ts';
|
||||
@@ -34,7 +34,7 @@ function validateCharacterOverrides(errors: string[]) {
|
||||
const overrides = readJsonFile<Record<string, unknown>>('src/data/characterOverrides.json');
|
||||
if (!expectPlainObject(errors, 'characterOverrides', overrides)) return;
|
||||
|
||||
const characterIds = new Set(PRESET_CHARACTERS.map(character => character.id));
|
||||
const characterIds = new Set(ROLE_TEMPLATE_CHARACTERS.map(character => character.id));
|
||||
const sceneIds = new Set(
|
||||
[WorldType.WUXIA, WorldType.XIANXIA].flatMap(worldType => getScenePresetsByWorld(worldType).map(scene => scene.id)),
|
||||
);
|
||||
@@ -142,7 +142,7 @@ function validateSceneNpcOverrides(errors: string[]) {
|
||||
getScenePresetsByWorld(worldType).flatMap(scene => scene.npcs.map(npc => npc.id)),
|
||||
),
|
||||
);
|
||||
const characterIds = new Set(PRESET_CHARACTERS.map(character => character.id));
|
||||
const characterIds = new Set(ROLE_TEMPLATE_CHARACTERS.map(character => character.id));
|
||||
|
||||
Object.entries(overrides).forEach(([npcId, override]) => {
|
||||
if (!npcIds.has(npcId)) {
|
||||
|
||||
Reference in New Issue
Block a user