From a8c6297071301a13435f29beeb9978f191ded138 Mon Sep 17 00:00:00 2001 From: cary <39078800+caryliu1999@users.noreply.github.com> Date: Wed, 9 Jun 2021 14:07:24 +0800 Subject: [PATCH] Delete array_a reset. (#31) --- cocos/core/scene-graph/node.ts | 4 ---- 1 file changed, 4 deletions(-) diff --git a/cocos/core/scene-graph/node.ts b/cocos/core/scene-graph/node.ts index 1bcc3d0906e..66e34df8b11 100644 --- a/cocos/core/scene-graph/node.ts +++ b/cocos/core/scene-graph/node.ts @@ -635,8 +635,6 @@ export class Node extends BaseNode { const childDirtyBit = dirtyBit | TransformBit.POSITION; array_a[0] = this; - // we need to recursively iterate this - // eslint-disable-next-line @typescript-eslint/no-this-alias let i = 0; while (i >= 0) { const cur: this = array_a[i--]; @@ -650,7 +648,6 @@ export class Node extends BaseNode { } dirtyBit = childDirtyBit; } - array_a.length = 0; } /** @@ -713,7 +710,6 @@ export class Node extends BaseNode { child._dirtyFlags = TransformBit.NONE; cur = child; } - array_a.length = 0; } // ===============================