From 3f62fde726904046e505d762e729b18568f5926d Mon Sep 17 00:00:00 2001 From: Tim Anema Date: Tue, 2 Dec 2014 21:45:19 -0500 Subject: [PATCH] fixed light range for scaling --- lib/light.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/light.lua b/lib/light.lua index 5b9b226..25e2d6e 100644 --- a/lib/light.lua +++ b/lib/light.lua @@ -122,7 +122,7 @@ function light:drawNormalShading(l,t,w,h,s, normalMap, shadowMap, canvas) self.shadowShader:send('shadowMap', shadowMap) self.shadowShader:send('lightColor', {self.red / 255.0, self.green / 255.0, self.blue / 255.0}) self.shadowShader:send("lightPosition", {(self.x + l/s) * s, (h/s - (self.y + t/s)) * s, (self.z * 10) / 255.0}) - self.shadowShader:send('lightRange',{self.range}) + self.shadowShader:send('lightRange',{self.range * s}) self.shadowShader:send("lightSmooth", self.smooth) self.shadowShader:send("lightGlow", {1.0 - self.glowSize, self.glowStrength}) self.shadowShader:send("lightAngle", math.pi - self.angle / 2.0)