sonic-radiance/sonic-radiance.love/game/modules/utils/init.lua
2019-07-26 17:36:25 +02:00

20 lines
467 B
Lua

local gameutils = {}
function gameutils.getMapPath(maptype, mapname)
if (maptype ~= "battle") then
error("Map type " .. maptype .. " doesn't exist.")
end
return "datas.gamedata.maps." .. maptype .. "." .. mapname
end
function gameutils.getMapDirectory(maptype, mapname)
if (maptype ~= "battle") then
error("Map type " .. maptype .. " doesn't exist.")
end
return "datas/gamedata/maps/" .. maptype .. "/" .. mapname .. "/"
end
return gameutils