mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-22 20:11:24 +01:00
Update routes-generator.js
Fix adding both directions for routes so that they are not duplicated.
This commit is contained in:
parent
ef31552cf1
commit
a1328abb14
1 changed files with 1 additions and 1 deletions
|
|
@ -94,7 +94,7 @@ window.Routes = (function () {
|
|||
}
|
||||
const [from, exit, passable] = findOceanPath(ports[a].cell, ports[b].cell);
|
||||
if (!passable) return null;
|
||||
formed[[a, b]] = true; formed[[b, a]]
|
||||
formed[[a, b]] = true; formed[[b, a]] = true;
|
||||
const path = restorePath(ports[a].cell, exit, "ocean", from);
|
||||
return path;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue