diff --git a/080g209iov.js b/080g209iov.js index e5c0faf..c94702e 100644 --- a/080g209iov.js +++ b/080g209iov.js @@ -15,6 +15,8 @@ if (GameLib.Utils.UndefinedOrNull(this.initialized)) { this.renderer = this.entityLoaded.renderer; this.raycaster = this.entityLoaded.raycaster; this.scene = this.entityLoaded.scene; + this.leftLight = this.entityLoaded.leftLight; + this.rightLight = this.entityLoaded.rightLight; this.throwerLight = this.entityLoaded.throwerLight; this.smokeParticleEngine = this.entityLoaded.smokeParticleEngine; this.fireParticleEngine = this.entityLoaded.fireParticleEngine; @@ -30,6 +32,8 @@ if (GameLib.Utils.UndefinedOrNull(this.initialized)) { this.parcel.instance.visible = false; this.santa.instance.visible = false; + this.treesBurning = 0; + /** * This component is initializing - set the total time to 0 */ @@ -319,6 +323,15 @@ if (GameLib.Utils.UndefinedOrNull(this.initialized)) { } else { mesh.burning = true; + this.treesBurning++; + + if (mesh.position.x < 0) { + this.leftLight.intensity += 0.1; + this.leftLight.color.r += 0.05; + this.leftLight.updateInstance('intensity'); + this.leftLight.updateInstance('color'); + } + // var smokeParticleEngine = this.smokeParticleEngine.clone(); // smokeParticleEngine.position = mesh.position.clone(); // smokeParticleEngine.updateInstance('position');