mirror of
https://github.com/ComfyFactory/ComfyFactorio.git
synced 2025-02-09 13:37:02 +02:00
Cave terrain fixes
This commit is contained in:
parent
72b5391ce8
commit
93636fd1c3
@ -128,7 +128,7 @@ function Public.roll_source_surface(destination_data)
|
|||||||
|
|
||||||
cave_miner.cave_surface = game.create_surface(cave_surface_name, map_gen_settings)
|
cave_miner.cave_surface = game.create_surface(cave_surface_name, map_gen_settings)
|
||||||
cave_miner.cave_surface.request_to_generate_chunks({x = 0, y = 0}, 2)
|
cave_miner.cave_surface.request_to_generate_chunks({x = 0, y = 0}, 2)
|
||||||
cave_miner.cave_surface.force_generate_chunk_requests()
|
-- cave_miner.cave_surface.force_generate_chunk_requests() -- Figure out if this is needed at all since it causes issues
|
||||||
end
|
end
|
||||||
|
|
||||||
function Public.cleanup_cave_surface(destination_data)
|
function Public.cleanup_cave_surface(destination_data)
|
||||||
|
@ -309,17 +309,18 @@ local function get_biome(args)
|
|||||||
end
|
end
|
||||||
|
|
||||||
function Public.terrain(args)
|
function Public.terrain(args)
|
||||||
|
local tiles_placed = #args.tiles
|
||||||
local biome, square_distance, noise = get_biome(args)
|
local biome, square_distance, noise = get_biome(args)
|
||||||
biome(args, square_distance, noise)
|
biome(args, square_distance, noise)
|
||||||
|
|
||||||
-- fallback case when no tiles were placed
|
-- fallback case when tile wasn't placed
|
||||||
if #args.tiles == 0 then
|
if tiles_placed == #args.tiles then
|
||||||
-- args.tiles[#args.tiles + 1] = {name = 'dirt-7', position = args.p}
|
args.tiles[#args.tiles + 1] = {name = 'dirt-7', position = args.p}
|
||||||
args.tiles[#args.tiles + 1] = {name = 'concrete', position = args.p}
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
-- Finding a spot for structures is very hard (it might cause structures to spawn in weird locations, like ship)
|
||||||
function Public.chunk_structures(args)
|
function Public.chunk_structures(args)
|
||||||
|
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user