summaryrefslogtreecommitdiffhomepage
path: root/not
diff options
context:
space:
mode:
Diffstat (limited to 'not')
-rw-r--r--not/Layer.lua6
-rw-r--r--not/World.lua4
2 files changed, 5 insertions, 5 deletions
diff --git a/not/Layer.lua b/not/Layer.lua
index 6be61c4..0446599 100644
--- a/not/Layer.lua
+++ b/not/Layer.lua
@@ -38,8 +38,12 @@ function Layer:clear ()
end
function Layer:draw ()
+ local scale = 1
+ if self.scale then
+ scale = getScale() / self.scale
+ end
love.graphics.setColor(255, 255, 255, 255)
- love.graphics.draw(self.canvas)
+ love.graphics.draw(self.canvas, 0, 0, 0, scale, scale)
end
return Layer
diff --git a/not/World.lua b/not/World.lua
index d3f126f..08b9710 100644
--- a/not/World.lua
+++ b/not/World.lua
@@ -33,10 +33,6 @@ function World:new (map, nauts)
local layer = Layer(320, 180)
layer.ratio = 0
layer.scale = 1
- layer.draw = function (self)
- love.graphics.setColor(255, 255, 255, 255)
- love.graphics.draw(self.canvas, 0, 0, 0, getScale(), getScale())
- end
table.insert(self.layers, layer) -- 7
end