diff options
author | Aki <nthirtyone@gmail.com> | 2017-09-02 22:30:32 +0200 |
---|---|---|
committer | Aki <nthirtyone@gmail.com> | 2017-09-02 22:30:32 +0200 |
commit | 2757fa1de92f2eff8be080721a7f777086afa072 (patch) | |
tree | d3564407bdd589304efbdd2dd93a3d9e21c656cd /not | |
parent | 27a1d0de613a360912d1e9f3a5db7ab044a0b450 (diff) | |
download | roflnauts-2757fa1de92f2eff8be080721a7f777086afa072.zip roflnauts-2757fa1de92f2eff8be080721a7f777086afa072.tar.gz roflnauts-2757fa1de92f2eff8be080721a7f777086afa072.tar.bz2 |
Separated platforms' configs from maps' configs
Diffstat (limited to 'not')
-rw-r--r-- | not/World.lua | 3 |
1 files changed, 2 insertions, 1 deletions
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 |