Explorar el Código

ScriptableNode: Fix getCacheKey() (#28964)

sunag hace 1 año
padre
commit
60a1f064e3
Se han modificado 1 ficheros con 14 adiciones y 0 borrados
  1. 14 0
      src/nodes/code/ScriptableNode.js

+ 14 - 0
src/nodes/code/ScriptableNode.js

@@ -437,6 +437,20 @@ class ScriptableNode extends Node {
 
 	}
 
+	getCacheKey( force ) {
+
+		const cacheKey = [ this.source, this.getDefaultOutputNode().getCacheKey( force ) ];
+
+		for ( const param in this.parameters ) {
+
+			cacheKey.push( this.parameters[ param ].getCacheKey( force ) );
+
+		}
+
+		return cacheKey.join( ',' );
+
+	}
+
 	set needsUpdate( value ) {
 
 		if ( value === true ) this.dispose();

粤ICP备19079148号