1#ifndef BOARDPARSER_H_DEFINED
2#define BOARDPARSER_H_DEFINED
4#include <Game/Board.hpp>
12class BoardParserException :
public std::exception
15 BoardParserException(std::string message):
18 ~BoardParserException()
throw()
24#define COMMENT_CHAR ';'
66 static bool save(
Board* board, std::string filename);
Opens, loads and parses a level file, returning a well-formed Board.
static Board * loadFile(std::string filename)
Loads and parses the level at filename.
static std::string directory
Default directory where the level files are.
static std::vector< std::string > listLevels()
Lists all levels found by the game.
static Board * load(std::string filename)
Loads and parses level with name.
static bool save(Board *board, std::string filename)
TODO.
static std::string extension
Default extension for nSnake level files.
A level where the snake runs and eats fruits.