Class PerfectGenerator

java.lang.Object
sac.model.generators.PerfectGenerator
All Implemented Interfaces:
Generator

public class PerfectGenerator extends Object implements Generator
PerfectGenerator guarantees the set-up of Perfect Clear.
Author:
Kai
  • Constructor Details

    • PerfectGenerator

      public PerfectGenerator()
      Initialize a set-up pack (including O,L,J,S,Z,T,I once) and a follow-up pack (including J,T,I once).
  • Method Details

    • nextPiece

      public Piece nextPiece()
      Specified by:
      nextPiece in interface Generator
      Returns:
      the next Piece generated by this generator
    • reset

      public void reset()
      Description copied from interface: Generator
      Reset this generator for new game.
      Specified by:
      reset in interface Generator