浏览代码

TSL: Fix Math/Operators fail generate cache with same node (#28502)

sunag 1 年之前
父节点
当前提交
23e68107bc
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      examples/jsm/nodes/core/Node.js

+ 3 - 1
examples/jsm/nodes/core/Node.js

@@ -199,9 +199,11 @@ class Node extends EventDispatcher {
 
 		const nodeProperties = builder.getNodeProperties( this );
 
+		let index = 0;
+
 		for ( const childNode of this.getChildren() ) {
 
-			nodeProperties[ '_node' + childNode.id ] = childNode;
+			nodeProperties[ 'node' + index ++ ] = childNode;
 
 		}