finish defense post

This commit is contained in:
evanpelle
2024-12-02 07:51:01 -08:00
parent d173e22b6b
commit 330b6b93cb
10 changed files with 31 additions and 10 deletions
+2 -1
View File
@@ -1,4 +1,4 @@
import { Cell, Tile } from "../game/Game";
import { Cell, TerrainType, Tile } from "../game/Game";
export interface AStar {
compute(): PathFindResultType
@@ -26,6 +26,7 @@ export interface SearchNode {
cost(): number
cell(): Cell
neighbors(): SearchNode[]
terrainType(): TerrainType
}
export interface Point {
x: number;
+1 -1
View File
@@ -21,7 +21,7 @@ export class MiniAStar implements AStar {
this.aStar = new SerialAStar(
miniSrc,
miniDst,
(t => (t as TerrainTile).terrainType() == TerrainType.Ocean),
canMove,
iterations,
maxTries
)