mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-19 02:21:24 +01:00
refactor: refactor religions expand
This commit is contained in:
parent
5361565cd7
commit
b9ff6a652c
13 changed files with 55 additions and 40 deletions
|
|
@ -103,7 +103,7 @@ export function generateRoutes(burgs: TBurgs, temp: Int8Array, cells: TCellsData
|
|||
|
||||
const segments = findPathSegments({isWater: true, cellRoutes, connections, start, exit});
|
||||
for (const segment of segments) {
|
||||
addConnections(segment, ROUTES.MAIN_ROAD);
|
||||
addConnections(segment, ROUTES.SEA_ROUTE);
|
||||
mainRoads.push({feature: Number(key), cells: segment});
|
||||
}
|
||||
});
|
||||
|
|
@ -118,7 +118,7 @@ export function generateRoutes(burgs: TBurgs, temp: Int8Array, cells: TCellsData
|
|||
const cellId = segment[i];
|
||||
const nextCellId = segment[i + 1];
|
||||
if (nextCellId) connections.set(`${cellId}-${nextCellId}`, true);
|
||||
cellRoutes[cellId] = roadTypeId;
|
||||
if (!cellRoutes[cellId]) cellRoutes[cellId] = roadTypeId;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue