MimicAgent

public class MimicAgent extends Agent

An agent that uses a map of turn numbers to action assignments to replay a series of actions.

Author:The Condor

Constructors

MimicAgent

public MimicAgent(int player, Map<Integer, ? extends Map<Integer, Action>> actions)

Creates a mimic agent that will blindly attempt to do a series of actions. Warning: copies the actual map and uses it. Edits to the map after passing it will alter the agent’s behaviour

Parameters:
  • player
  • actions – A map of step numbers to the map to return for that step.

Methods

initialStep

public Map<Integer, Action> initialStep(StateView newstate, HistoryView statehistory)

loadPlayerData

public void loadPlayerData(InputStream is)

middleStep

public Map<Integer, Action> middleStep(StateView newstate, HistoryView statehistory)

savePlayerData

public void savePlayerData(OutputStream os)

terminalStep

public void terminalStep(StateView newstate, HistoryView statehistory)