public interface Agent
Modifier and Type | Method and Description |
---|---|
void |
act()
Inform the agent that it is time to act for this cycle.
|
void |
enterGrid(SimulationGrid grid,
int xPos,
int yPos)
Inform the agent that it has been placed on the grid.
|
java.awt.Color |
getColor()
Return a color appropriate for displaying this agent's icon
in color displays.
|
String |
getIcon()
Get a character representation of this agent.
|
int |
weight()
Report on the weight of this agent.
|
void enterGrid(SimulationGrid grid, int xPos, int yPos)
grid
- The grid in which the agent has been placed.xPos
- The agent's x-position in the gridyPos
- The agent's y-position in the gridvoid act()
int weight()
String getIcon()
java.awt.Color getColor()