From 5a30d7898b461cc5449a850dc4d79f4f0a65b60f Mon Sep 17 00:00:00 2001 From: -=yb4f310 Date: Wed, 7 Mar 2018 06:03:34 +0100 Subject: [PATCH] Update: CC - Before Render - Moorcow (qemp4een6t.js) 604 bytes modified --- qemp4een6t.js | 44 ++++++++++---------------------------------- 1 file changed, 10 insertions(+), 34 deletions(-) diff --git a/qemp4een6t.js b/qemp4een6t.js index 92fd5c0..e26c656 100644 --- a/qemp4een6t.js +++ b/qemp4een6t.js @@ -46,8 +46,7 @@ if (GameLib.Utils.UndefinedOrNull(this.initialized)) { this.meshes = this.entityLoaded.meshes; this.raycaster = this.entityLoaded.raycaster; this.kanister = this.entityLoaded.kanister; - this.leftLight = this.entityLoaded.leftLight; - this.rightLight = this.entityLoaded.rightLight; + this.lightDirectional = this.entityLoaded.lightDirectional; this.scoreCanvas = this.entityLoaded.scoreCanvas; this.scoreTexture = this.entityLoaded.scoreTexture; this.scoreMesh = this.entityLoaded.scoreMesh; @@ -162,19 +161,8 @@ if (GameLib.Utils.UndefinedOrNull(this.initialized)) { this.enemiesSpawned = 0; - - this.leftLight.intensity = 0.3; - this.leftLight.updateInstance('intensity'); - this.rightLight.intensity = 0.3; - this.rightLight.updateInstance('intensity'); - - GameLib.Event.Emit( - GameLib.Event.GET_GRAPHICS_IMPLEMENTATION, - null, - function (graphics) { - this.graphics = graphics - }.bind(this) - ); + this.lightDirectional.intensity = 0; + this.lightDirectional.updateInstance('intensity'); this.setLevelProperties = function () { @@ -625,26 +613,14 @@ if (GameLib.Utils.UndefinedOrNull(this.initialized)) { this.minimumRendererRed += 0.01; - if (mesh.position.x < 0) { - this.leftLight.intensity += data.delta * 2.5; - - if (this.leftLight.intensity >= 1) { - this.leftLight.intensity = 1; - } - - this.leftLight.updateInstance('intensity'); - - } else { - this.rightLight.intensity += data.delta * 2.5; - - if (this.rightLight.intensity >= 1) { - this.rightLight.intensity = 1; - } - - this.rightLight.updateInstance('intensity'); + this.lightDirectional.intensity += 0.1; + if (this.lightDirectional.intensity >= 1.4) { + this.lightDirectional.intensity = 1.4; } - + + this.lightDirectional.updateInstance('intensity'); + mesh.burningTreeParticleEngine.enabled = true; GameLib.Event.Emit( @@ -684,7 +660,7 @@ this.scene.meshes.map( if (this.mouseIsDown) { this.kanisterTime += data.delta * 1.125; - + this.throwerLight.intensity += 0.05; if (this.throwerLight.intensity > 2) { this.throwerLight.intensity = 2;