diff --git a/ip0443a52d.js b/ip0443a52d.js index 5833b4a..dec31c4 100644 --- a/ip0443a52d.js +++ b/ip0443a52d.js @@ -15,6 +15,9 @@ if (!this.initialized) { this.boxGeometry = this.entityLoaded.boxGeometry; this.instancedGeometry = this.entityLoaded.instancedGeometry; + this.textureWhite = this.entityLoaded.textureWhite; + this.materialRawPhong = this.entityLoaded.materialRawPhong; + this.initialized = true; console.log('key up initialized'); @@ -49,10 +52,11 @@ if (data.code === 'KeyL') { var uniforms = Object.assign( THREE.UniformsLib['lights'], { - map: { value: texture } + map: { value: this.textureWhite.instance } } - ); - + ); + + this.materialRawPhong.instance.uniforms = uniforms; this.instancedGeometry.instance.index = this.boxGeometry.instance.index; this.instancedGeometry.instance.groups = this.boxGeometry.instance.groups;