Interface AdHocClock

interface AdHocClock {
    black_player_id: number;
    black_time: number | AdHocPlayerClock;
    current_player: number;
    expiration: number;
    game_id: number;
    last_move: number;
    pause?: {
        pause_control: AdHocPauseControl;
        paused: boolean;
        paused_since: number;
    };
    paused_since?: number;
    start_mode?: boolean;
    title: string;
    white_player_id: number;
    white_time: number | AdHocPlayerClock;
}

Properties

black_player_id: number

OGS player id for black

black_time: number | AdHocPlayerClock

Time left on black's clock. If this is a number (such as is the case with simple time), it is expressed in milliseconds.

current_player: number

Current player to move

expiration: number

Time the game will end if no move is played, in milliseconds since 1970. This is computed by adding together any main and overtime left on the clock. If start_mode is set, this is the number of milliseconds left on the start clock.

game_id: number

OGS Game id

last_move: number

Time the last move was made, in milliseconds since 1970

pause?: {
    pause_control: AdHocPauseControl;
    paused: boolean;
    paused_since: number;
}

If set, this AdHocClock is updating the pause state

Type declaration

paused_since?: number

Time the game was paused. This field erroneously exists even after the game has been resumed, this will be removed in these cases.

start_mode?: boolean

If true, the game has not started and this is the count down until the game is canceled if a move has not been played yet. If this is true, then the duration left on the start clock is stored in expiration (in ms)

title: string

Title of the game. This field will be removed.

white_player_id: number

OGS player id for white

white_time: number | AdHocPlayerClock

Time left on white's clock. If this is a number (such as is the case with simple time), it is expressed in milliseconds.k