|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.jetrix.filter.DownstackPuzzleGenerator
public class DownstackPuzzleGenerator
Puzzle generator supporting the puzzle format used by the 2ice server, aka downstack.com. Each puzzle consists in two files, a .field file containing the description of the field, and a .settings file containing the game settings and the puzzle description. By default the puzzle files are looked for in the data/puzzle sub directory, this can be overridden by setting the path parameter.
| Field Summary | |
|---|---|
static Block[] |
BLOCKS
The order or the specials used in the settings file. |
| Constructor Summary | |
|---|---|
DownstackPuzzleGenerator()
|
|
| Method Summary | |
|---|---|
protected File[] |
getLevels()
Find all levels in the puzzle directory. |
Puzzle |
getNextPuzzle()
Generates the next puzzle. |
void |
init(Configuration config)
Initializes the generator. |
protected Puzzle |
loadPuzzle(File directory,
String name)
Load a puzzle from the filesystem. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final Block[] BLOCKS
| Constructor Detail |
|---|
public DownstackPuzzleGenerator()
| Method Detail |
|---|
public void init(Configuration config)
PuzzleGenerator
init in interface PuzzleGeneratorconfig - the configuration containing the configuration parameters.public Puzzle getNextPuzzle()
PuzzleGenerator
getNextPuzzle in interface PuzzleGenerator
protected Puzzle loadPuzzle(File directory,
String name)
throws IOException
directory - the directory containing the puzzle filename - the name of the puzzle
IOExceptionprotected File[] getLevels()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||