浏览代码

CSM.remove() removes the targets, too (#24658)

Yoshiki Ohshima 2 年之前
父节点
当前提交
4de773d68a
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      examples/jsm/csm/CSM.js

+ 1 - 0
examples/jsm/csm/CSM.js

@@ -343,6 +343,7 @@ export class CSM {
 
 
 		for ( let i = 0; i < this.lights.length; i ++ ) {
 		for ( let i = 0; i < this.lights.length; i ++ ) {
 
 
+			this.parent.remove( this.lights[ i ].target );
 			this.parent.remove( this.lights[ i ] );
 			this.parent.remove( this.lights[ i ] );
 
 
 		}
 		}