MapGen: move ff2luat.lua Api->MapGen
This commit is contained in:
@@ -41,6 +41,8 @@ local Triangulation = require('MapGen.Triangulation')
|
||||
---@type MapGen.Cavern
|
||||
local Cavern = require('MapGen.Cavern')
|
||||
|
||||
local ff2luat = require('MapGen.ff2luat')
|
||||
|
||||
---@class MapGen
|
||||
---@field layersByName table<string, MapGen.Layer>
|
||||
---@field layersList MapGen.Layer[]
|
||||
@@ -250,7 +252,7 @@ end
|
||||
---@param groups? table<string, number>
|
||||
function MapGen:register2DPeaksFromFile(layerName, map, scale,zeroPos, category, groups)
|
||||
local modPath = core.get_modpath(core.get_current_modname())
|
||||
local peaks = Api.ff2luat(modPath .. '/textures/maps/' .. map)
|
||||
local peaks = ff2luat(modPath .. '/textures/maps/' .. map)
|
||||
|
||||
local mapSize = peaks.size
|
||||
peaks.size = nil
|
||||
@@ -901,10 +903,6 @@ function MapGen:run()
|
||||
self:initLayersTriangultaion()
|
||||
|
||||
MapGen.isRunning = true
|
||||
|
||||
for _, peak in ipairs(self.layersList[1].peaksList["landscape"]) do
|
||||
print(tostring(peak))
|
||||
end
|
||||
end
|
||||
|
||||
return MapGen
|
||||
|
||||
Reference in New Issue
Block a user