Browse Source

fix: avoid assigning args as BufferAttribute to BufferGeometry

alvarosabu 2 years ago
parent
commit
1cc67b08c1
1 changed files with 1 additions and 0 deletions
  1. 1 0
      src/core/nodeOps.ts

+ 1 - 0
src/core/nodeOps.ts

@@ -132,6 +132,7 @@ export const nodeOps: RendererOptions<TresObject, TresObject> = {
       let target = root?.[finalKey]
       let target = root?.[finalKey]
 
 
       if (root.type === 'BufferGeometry') {
       if (root.type === 'BufferGeometry') {
+        if (key === 'args') return
         root.setAttribute(
         root.setAttribute(
           kebabToCamel(key),
           kebabToCamel(key),
           new BufferAttribute(...(nextValue as ConstructorParameters<typeof BufferAttribute>)),
           new BufferAttribute(...(nextValue as ConstructorParameters<typeof BufferAttribute>)),