RatedMatch

open class RatedMatch(val white: Player, val black: Player, val eloCalculator: EloCalculator) : Match

Represents a standard competitive match between two Players. This class handles the automation of score accumulation, Elo rating updates, and opponent tracking once an outcome is reached.

Author

lunalobos

Since

1.0.0-beta.8

Constructors

Link copied to clipboard
constructor(white: Player, black: Player, eloCalculator: EloCalculator)

Properties

Link copied to clipboard
open override val black: Player

The player assigned the black pieces.

Link copied to clipboard

The logic used to adjust ratings post-match.

Link copied to clipboard
open override var outcome: Outcome

The current state/result of the match. Setting this value (except to SUSPENDED) triggers:

Link copied to clipboard
open override val white: Player

The player assigned the white pieces.

Functions

Link copied to clipboard

Calculates the Sonneborn-Berger partial score for a specific player.

Link copied to clipboard
open override fun toString(): String