From 2757fa1de92f2eff8be080721a7f777086afa072 Mon Sep 17 00:00:00 2001 From: Aki Date: Sat, 2 Sep 2017 22:30:32 +0200 Subject: Separated platforms' configs from maps' configs --- not/World.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'not') diff --git a/not/World.lua b/not/World.lua index 7d40476..d4d933f 100644 --- a/not/World.lua +++ b/not/World.lua @@ -52,7 +52,8 @@ function World:loadMap (name) self.map = map() -- Platforms for _,platform in pairs(self.map.platforms) do - self:createPlatform(platform.x, platform.y, platform.shape, platform.sprite, platform.animations) + local config = love.filesystem.load(string.format("config/platforms/%s.lua", platform.config))() + self:createPlatform(platform.x, platform.y, config.shape, config.sprite, platform.animations) end -- Decorations for _,decoration in pairs(self.map.decorations) do -- cgit v1.1