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

Method update

packages/core/src/Utils/Pool/PoolManager.ts:39–46  ·  view source on GitHub ↗

* 更新池管理器(应在游戏循环中调用)

()

Source from the content-addressed store, hash-verified

37 * 更新池管理器(应在游戏循环中调用)
38 */
39 public update(): void {
40 const now = Date.now();
41
42 if (now - this.lastCompactTime > this.autoCompactInterval) {
43 this.compactAllPools();
44 this.lastCompactTime = now;
45 }
46 }
47
48 /**
49 * 创建或获取标准池

Callers

nothing calls this directly

Calls 2

compactAllPoolsMethod · 0.95
nowMethod · 0.80

Tested by

no test coverage detected