static Map BuildMap(RawChart[] charts, Coord[] offsets, int seed) { var modules = charts.Select(chart => MapGenStaticMap.Construct(chart.Map)).ToArray(); var compoundModule = MapGenCompound.Construct(modules, offsets.Select(coord => (Vector2)coord)); Map map = compoundModule.Generate(seed); return(map); }
ChartStatic CarveEntrancesIntoChart(RawChart chart, Maze maze, Coord coord) { IEnumerable<MapEntrance> entrances = GetEntrances(maze, coord); chart.Seed = seed; var staticModule = MapGenStaticMap.Construct(chart.Map); var carvedModule = MapGenEntranceCarver.Construct(staticModule, entrances); return ChartStatic.ReplaceMap(carvedModule.Generate(seed), chart); }