public class Agent extends AbstractPlayer
Modifier and Type | Field and Description |
---|---|
protected int |
block_size
block size
|
protected java.util.ArrayList<Observation>[][] |
grid
Observation grid.
|
protected java.util.Random |
randomGenerator
Random generator for the agent.
|
Constructor and Description |
---|
Agent(StateObservation so,
ElapsedCpuTimer elapsedTimer)
Public constructor with state observation and time due.
|
Modifier and Type | Method and Description |
---|---|
Types.ACTIONS |
act(StateObservation stateObs,
ElapsedCpuTimer elapsedTimer)
Picks an action.
|
void |
draw(java.awt.Graphics2D g)
Gets the player the control to draw something on the screen.
|
act
getAllActions, getLastAction, getPlayerID, isHuman, logAction, result, resultMulti, setPlayerID, setup, teardown
protected java.util.Random randomGenerator
protected java.util.ArrayList<Observation>[][] grid
protected int block_size
public Agent(StateObservation so, ElapsedCpuTimer elapsedTimer)
so
- state observation of the current game.elapsedTimer
- Timer for the controller creation.public Types.ACTIONS act(StateObservation stateObs, ElapsedCpuTimer elapsedTimer)