MCPcopy Create free account
hub / github.com/esengine/esengine / removeWorld

Method removeWorld

packages/core/src/ECS/WorldManager.ts:123–135  ·  view source on GitHub ↗

* 移除World

(worldName: string)

Source from the content-addressed store, hash-verified

121 * 移除World
122 */
123 public removeWorld(worldName: string): boolean {
124 const world = this._worlds.get(worldName);
125 if (!world) {
126 return false;
127 }
128
129 // 销毁World
130 world.destroy();
131 this._worlds.delete(worldName);
132
133 logger.info(`移除World: ${worldName}`);
134 return true;
135 }
136
137 /**
138 * 获取World

Callers 3

cleanupMethod · 0.95
destroyMethod · 0.95

Calls 4

getMethod · 0.65
destroyMethod · 0.65
deleteMethod · 0.65
infoMethod · 0.45

Tested by

no test coverage detected