mirror of
https://github.com/tanema/light_world.lua.git
synced 2024-12-24 20:24:19 +00:00
almost got scaling working
This commit is contained in:
parent
b1c366e236
commit
b2b6a97f54
@ -238,14 +238,18 @@ function light_world:draw(l,t,w,h,s)
|
|||||||
local last_buffer = love.graphics.getCanvas()
|
local last_buffer = love.graphics.getCanvas()
|
||||||
love.graphics.setCanvas(self.render_buffer)
|
love.graphics.setCanvas(self.render_buffer)
|
||||||
|
|
||||||
self.drawBackground(l,t,w,h,s)
|
love.graphics.push()
|
||||||
self:drawShadow(l,t,w,h,scale)
|
love.graphics.scale(1/s)
|
||||||
self.drawForground(l,t,w,h,s)
|
l, t, w, h = (l*s), (t*s), (w*s), (h*s)
|
||||||
self:drawShine(l,t,w,h,scale)
|
self.drawBackground( l,t,w,h,s)
|
||||||
self:drawPixelShadow(l,t,w,h,scale)
|
self:drawShadow( l,t,w,h,s)
|
||||||
self:drawGlow(l,t,w,h,scale)
|
self.drawForground( l,t,w,h,s)
|
||||||
self:drawRefraction(l,t,w,h,scale)
|
self:drawShine( l,t,w,h,s)
|
||||||
self:drawReflection(l,t,w,h,scale)
|
self:drawPixelShadow( l,t,w,h,s)
|
||||||
|
self:drawGlow( l,t,w,h,s)
|
||||||
|
self:drawRefraction( l,t,w,h,s)
|
||||||
|
self:drawReflection( l,t,w,h,s)
|
||||||
|
love.graphics.pop()
|
||||||
|
|
||||||
love.graphics.setBackgroundColor(0, 0, 0)
|
love.graphics.setBackgroundColor(0, 0, 0)
|
||||||
love.graphics.setBlendMode("alpha")
|
love.graphics.setBlendMode("alpha")
|
||||||
|
Loading…
Reference in New Issue
Block a user