randomMovePlayer: Player that picks a random move

Description Usage Arguments Value Examples

View source: R/players.R

Description

Internally this player calls getMoves and then picks an entry in the list of moves at random.

A player is a function that takes a game state as input and returns a valid move index.

Usage

1

Arguments

gameState

The gameState that the player should act on.

Value

moveIndex Index to a valid move as returned by the getMoves function.

Examples

1
2

rt3 documentation built on May 29, 2017, 8 p.m.