refactor: river generation continue

This commit is contained in:
max 2022-07-20 01:21:55 +03:00
parent 4e65616dbc
commit cd86c61b79
6 changed files with 196 additions and 131 deletions

View file

@ -24,8 +24,13 @@ export function createPack(grid: IGrid): IPack {
const markup = markupPackFeatures(grid, vertices, pick(cells, "v", "c", "b", "p", "h"));
const {features, featureIds, distanceField, haven, harbor} = markup;
const riverCells = {...cells, f: featureIds, t: distanceField, haven};
Rivers.generate(grid, {cells: riverCells, features}, true);
Rivers.generate(
grid.cells.prec,
grid.cells.temp,
pick({...cells, f: featureIds, t: distanceField, haven}, "i", "c", "b", "g", "t", "h", "f", "haven"),
features,
true
);
// Lakes.defineGroup(newPack);
// Biomes.define(newPack, grid);