1
0
mirror of https://github.com/Refactorio/RedMew.git synced 2025-03-03 14:53:01 +02:00
RedMew/map_layout.lua

56 lines
1.5 KiB
Lua
Raw Normal View History

2017-07-14 20:12:28 +02:00
--[[
2017-07-20 23:22:09 +02:00
This file is used to choose which styles you want.
You may choose up to one of each type shapes, terrain, ores and misc by removing uncommenting the line.
If you want to add your own module, just add it to the others
in this file and your run_*type*_module(event) function will be called.
2017-07-14 20:12:28 +02:00
--]]
--shapes--
--require "locale.gen_shape.right"
--require "locale.gen_shape.up"
--require "locale.gen_shape.maze"
2017-07-14 20:12:28 +02:00
--require "locale.gen_shape.spiral"
--require "locale.gen_shape.spiral_tri"
--require "locale.gen_shape.spiral2"
--require "locale.gen_shape.donut"
2017-07-20 23:22:09 +02:00
--require "locale.gen_shape.rectangular_spiral"
2017-07-29 11:07:08 +01:00
--require "locale.gen_shape.x_map"
require "locale.gen_shape.x_infinite"
2017-07-20 23:22:09 +02:00
2017-07-14 20:12:28 +02:00
--terrain--
2017-07-18 21:54:54 +02:00
--require "locale.gen_terrain.neko_bridged_rivers"
2017-07-14 20:12:28 +02:00
--ores--
--require "locale.gen_ores.neko_crazy_ores"
2017-07-18 21:54:54 +02:00
--everything else. You may use more than one of these, but beware they might not be compatible
miscs = {}
--miscs[1] = require "locale.gen_misc.rail_grid"
2017-07-14 20:12:28 +02:00
local on_chunk_generated = function(event)
if run_shape_module ~= nil then
2017-07-14 20:12:28 +02:00
if run_shape_module(event) then
if run_terrain_module ~= nil then
2017-07-14 20:12:28 +02:00
run_terrain_module(event)
elseif run_ores_module ~= nil then
2017-07-18 19:47:48 +02:00
run_ores_module(event)
2017-07-14 20:12:28 +02:00
end
end
else
if run_terrain_module ~= nil then
2017-07-18 19:47:48 +02:00
run_terrain_module(event)
elseif run_ores_module ~= nil then
2017-07-18 19:47:48 +02:00
run_ores_module(event)
2017-07-14 20:12:28 +02:00
end
end
2017-07-18 21:54:54 +02:00
for _,v in pairs(miscs) do
v.on_chunk_generated(event)
end
2017-07-14 20:12:28 +02:00
end
Event.register(defines.events.on_chunk_generated, on_chunk_generated)