Class Legacy

java.lang.Object
game.controllers.ghosts.GhostsControllerBase
game.controllers.ghosts.examples.Legacy
All Implemented Interfaces:
IGhostsController

public class Legacy
extends GhostsControllerBase
  • Field Summary

    Fields inherited from class game.controllers.ghosts.GhostsControllerBase

    ghostCount, input
  • Constructor Summary

    Constructors 
    Constructor Description
    Legacy()  
  • Method Summary

    Modifier and Type Method Description
    void tick​(Game game, long timeDue)
    Perform action-selection for all ghosts based on information from Game.

    Methods inherited from class game.controllers.ghosts.GhostsControllerBase

    getActions, getGhostCount, nextLevel, reset

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • tick

      public void tick​(Game game, long timeDue)
      Description copied from interface: IGhostsController
      Perform action-selection for all ghosts based on information from Game.

      Persist your decision within PacManAction that is periodically read via #getAction().
      Specified by:
      tick in interface IGhostsController
      Specified by:
      tick in class GhostsControllerBase
      Parameters:
      game - current state of the game
      timeDue - how much time (in millis) do you have for your action-selection before #getAction() will get called.