refactor(modules): 适配新的组件注册接口
更新各模块 RuntimeModule 使用 IComponentRegistry 接口: - audio, behavior-tree, camera - sprite, tilemap, world-streaming
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import type { IScene, ServiceContainer } from '@esengine/ecs-framework';
|
||||
import { ComponentRegistry } from '@esengine/ecs-framework';
|
||||
import type { IScene, ServiceContainer, IComponentRegistry } from '@esengine/ecs-framework';
|
||||
import type { IRuntimeModule, SystemContext } from '@esengine/engine-core';
|
||||
import { ChunkComponent } from './components/ChunkComponent';
|
||||
import { StreamingAnchorComponent } from './components/StreamingAnchorComponent';
|
||||
@@ -22,7 +21,7 @@ export class WorldStreamingModule implements IRuntimeModule {
|
||||
return this._chunkManager;
|
||||
}
|
||||
|
||||
registerComponents(registry: typeof ComponentRegistry): void {
|
||||
registerComponents(registry: IComponentRegistry): void {
|
||||
registry.register(ChunkComponent);
|
||||
registry.register(StreamingAnchorComponent);
|
||||
registry.register(ChunkLoaderComponent);
|
||||
|
||||
Reference in New Issue
Block a user