|
|
|
@ -2,13 +2,16 @@ export type NodeId = string; |
|
|
|
|
|
|
|
export type Difficulty = "easy" | "normal" | "hard"; |
|
|
|
|
|
|
|
export type GameStatus = "idle" | "running" | "won" | "lost"; |
|
|
|
export type GameStatus = "setup" | "playing" | "win" | "lose"; |
|
|
|
|
|
|
|
export interface GraphNode { |
|
|
|
id: NodeId; |
|
|
|
q: number; |
|
|
|
r: number; |
|
|
|
neighbors: NodeId[]; |
|
|
|
} |
|
|
|
|
|
|
|
export interface GameGraph { |
|
|
|
nodes: Record<NodeId, GraphNode>; |
|
|
|
edgeList: Array<[NodeId, NodeId]>; |
|
|
|
} |
|
|
|
|