Reworking the junkmap

This commit is contained in:
2014-06-13 01:21:50 -07:00
parent 8175a46374
commit d5cec02e5f

View File

@@ -926,7 +926,7 @@ GameState.prototype.updateShadowTexture = function() {
// Iterate through each of the lights and draw the glow // Iterate through each of the lights and draw the glow
this.staticLights.forEach(function(light) { this.staticLights.forEach(function(light) {
// Don't draw lights that aren't on screen // Don't draw lights that aren't on screen
if ( light.always_render !== true ) if ( light.always_render !== true ) {
var r1 = new Phaser.Rectangle(this.game.camera.x, var r1 = new Phaser.Rectangle(this.game.camera.x,
this.game.camera.y, this.game.camera.y,
this.game.camera.width, this.game.camera.width,
@@ -935,6 +935,7 @@ GameState.prototype.updateShadowTexture = function() {
console.log("Light does not appear on camera"); console.log("Light does not appear on camera");
return; return;
} }
}
if ( light.flicker ) { if ( light.flicker ) {
// Randomly change the radius each frame // Randomly change the radius each frame