fix: IDataCommon 漏写 enemyStore

This commit is contained in:
unanmed 2026-10-20 21:25:16 +08:00
parent e54ea3b13e
commit a7dc542671
3 changed files with 15 additions and 2 deletions

View File

@ -1,3 +1,4 @@
export * from './enemyStore';
export * from './eventStore';
export * from './itemStore';
export * from './mapStore';

View File

@ -1,5 +1,11 @@
import { IFaceManager, IRoleFaceBinder } from './common';
import { IGameEventStore, IItemStore, IMapStore, ITileStore } from './store';
import {
IEnemyStore,
IGameEventStore,
IItemStore,
IMapStore,
ITileStore
} from './store';
import { IReplaySystem } from './replay';
import { IEnemyView } from '@user/data-system';
import { IHookable, IHookBase } from '@motajs/common';
@ -66,6 +72,8 @@ export interface IDataCommon extends IHookable<IDataCommonHooks> {
readonly mapStore: IMapStore;
/** 游戏事件存储 */
readonly eventStore: IGameEventStore;
/** 怪物定义存储 */
readonly enemyStore: IEnemyStore<IEnemyAttr>;
/** 朝向绑定 */
readonly roleFace: IRoleFaceBinder;
/** 朝向管理 */

View File

@ -24,7 +24,9 @@ import {
MapStore,
IReplaySystem,
ReplaySystem,
IDataCommonHooks
IDataCommonHooks,
IEnemyStore,
EnemyStore
} from '@user/data-common';
import {
EnemyManager,
@ -68,6 +70,7 @@ export class CoreState
readonly faceManager: IFaceManager;
readonly tileStore: ITileStore;
readonly itemStore: IItemStore<IHeroAttr>;
readonly enemyStore: IEnemyStore<IEnemyAttr>;
readonly mapStore: IMapStore;
readonly eventStore: IGameEventStore;
readonly replaySystem: IReplaySystem;
@ -112,6 +115,7 @@ export class CoreState
this.itemStore = new ItemStore<IHeroAttr>(this.tileStore);
this.mapStore = new MapStore();
this.eventStore = new GameEventStore();
this.enemyStore = new EnemyStore(this.tileStore);
this.replaySystem = new ReplaySystem();
// L1 定义