/* Level class module stores information of the generation of Block(s) */ #ifndef _LEVEL_H_ #define _LEVEL_H_ #include <memory> #include <string> #include <map> #include <random> #include <fstream> class Level { int level; bool isRandom; std::string defaultFile; std::ifstream defaultStream; std::string sequenceFile; std::ifstream sequenceStream; static std::default_random_engine generator; static std::map<int,std::discrete_distribution<int>> distributions; static std::map<int,char> blockTypes; public: static const int MAX_LEVEL; static const int MIN_LEVEL; Level(int level, int seed, std::string file = ""); ~Level(); char nextBlock(); void setRandom(bool active); void setSequence(std::string file); void levelUp(); void levelDown(); }; #endif