UNPKG

goban-engine

Version:

This contains the built Go engine that is used by the Goban package. There are no display components in this package, only the logic for playing the game of Go, making it suitable for usage in node.js or other server-side environments.

26 lines (25 loc) 1.27 kB
import { JGOFNumericPlayerColor, JGOFSealingIntersection, JGOFMove } from "./formats/JGOF"; import { GobanEngineRules } from "./GobanEngine"; interface AutoscoreResults { result: JGOFNumericPlayerColor[][]; sealed_result: JGOFNumericPlayerColor[][]; removed: JGOFMove[]; needs_sealing: JGOFSealingIntersection[]; } export declare function autoscore(board: JGOFNumericPlayerColor[][], rules: GobanEngineRules, black_plays_first_ownership: number[][], white_plays_first_ownership: number[][]): [AutoscoreResults, DebugOutput]; export declare function white(str: string): string; export declare function red(str: string): string; export declare function green(str: string): string; export declare function yellow(str: string): string; export declare function blue(str: string): string; export declare function magenta(str: string): string; export declare function cyan(str: string): string; export declare function black(str: string): string; export declare function whiteBright(str: string): string; export declare function cyanBright(str: string): string; export declare function blackBright(str: string): string; /******************************/ /*** Debug output functions ***/ /******************************/ type DebugOutput = string; export {};