Skip to content

Commit

Permalink
fix: can't do getTilePathfrom 0,0 (#419)
Browse files Browse the repository at this point in the history
  • Loading branch information
lajbel authored Oct 19, 2024
1 parent 4fa615f commit e1e9263
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/game/level.ts
Original file line number Diff line number Diff line change
Expand Up @@ -590,7 +590,7 @@ export function addLevel(
while (node !== start) {
let cameNode = cameFrom.get(node);

if (!cameNode) {
if (cameNode === undefined) {
throw new Error("Bug in pathfinding algorithm");
}

Expand Down

0 comments on commit e1e9263

Please sign in to comment.