simulation_InteractiveVersion.gameWorlds
Class SkitteryWorld
java.lang.Object
simulation_InteractiveVersion.gameWorlds.GameWorldModel
simulation_InteractiveVersion.gameWorlds.SkitteryWorld
public class SkitteryWorld
- extends GameWorldModel
This class encapsulates a world that consists of a single ImageSprite that
moves about in a very skittery manner (random movements in all possible
directions).
- Author:
- mb
Constructor Summary |
SkitteryWorld(int worldWidth,
int worldHeight)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SkitteryWorld
public SkitteryWorld(int worldWidth,
int worldHeight)
advanceNextState
public void advanceNextState()
- Description copied from class:
GameWorldModel
- Updates the data model to reflect whatever actions occur in the duration
of one new frame. Draws the game world on the passed Graphics2D instance.
- Overrides:
advanceNextState
in class GameWorldModel
drawCurrentState
public void drawCurrentState(java.awt.Graphics2D graphics)
- Overrides:
drawCurrentState
in class GameWorldModel
addAnotherSprite
public void addAnotherSprite()
- Overrides:
addAnotherSprite
in class GameWorldModel