废弃core.scene更改为setscene方法

This commit is contained in:
YHH
2025-08-12 11:08:27 +08:00
parent 86cb70a94f
commit 56dd18b983
13 changed files with 96 additions and 85 deletions

View File

@@ -54,7 +54,7 @@ import { Core, Scene, Entity, Component, EntitySystem, Matcher, Time } from '@es
// 创建核心实例
const core = Core.create({ debug: true });
const scene = new Scene();
Core.scene = scene;
Core.setScene(scene);
// 定义组件
class PositionComponent extends Component {