Browse Source

BabylonLoader: Inverting z for lights too.

Mr.doob 12 năm trước cách đây
mục cha
commit
89041aebf5
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      examples/js/loaders/BabylonLoader.js

+ 1 - 1
examples/js/loaders/BabylonLoader.js

@@ -99,7 +99,7 @@ THREE.BabylonLoader.prototype = {
 			}
 
 			light.name = data.name;
-			light.position.fromArray( data.data );
+			light.position.set( data.data[ 0 ], data.data[ 1 ], - data.data[ 2 ] );
 			light.color.fromArray( data.diffuse );
 			if ( data.intensity ) light.intensity = data.intensity;