Move constructor

const Move(
  1. Square from,
  2. Square to, [
  3. Piece? promotionTo
])

Constructs new Move object for move from square to square.

Implementation

const Move(this.from, this.to, [this.promotionTo]);