iterami/Docs.htm/common HTM Projects/chess.js/chess_validate(args)
- Checks if the requested move is valid or not.
- Returns an object of properties describing the requested move.
- Can optionally ignore current turn and check hypothetical moves.
- Can optionally accept a specific board as an array of strings, or else will just use the board from the game id.
board
| void 0
| array of strings
|
id
|
| string
|
piece-x
|
| number 0-7
|
piece-y
|
| number 0-7
|
player
|
| 0 or 1
|
target-x
|
| number 0-7
|
target-y
|
| number 0-7
|
threat
| false
| boolean
|