#ifndef RESOURCEMANAGER_H #define RESOURCEMANAGER_H #include #include #include #include #include #include #include #include //#include #include "MazeMap.h" class ResourceManager { public: ResourceManager() : textureTileSize(8) {}; bool loadTexture(const std::string& textureName, const std::filesystem::path& texturePath); bool loadFont(const std::string& fontName, const std::filesystem::path& fontPath); bool loadMap(const std::string& mapName, const std::filesystem::path& mapPath); bool loadSound(const std::string& soundName, const std::filesystem::path& soundPath); sf::Texture& getTexture(const std::string& textureName) { return *textures[textureName]; }; void resizeTexture(const std::string& textureName, unsigned int newTextureTileSize); std::vector& getMazeMap() { return mazeMap; } std::vector& getPelletMap() { return pelletMap; } sf::SoundBuffer* getSound(const std::string& soundName) { return &sounds[soundName]; }; sf::Font& getFont(const std::string& fontName) { return fonts[fontName]; }; //load gameplay info private: //textures and sprites std::map> textures; const int textureTileSize; //fonts std::map fonts; //sounds std::map sounds; //map std::vector mazeMap; std::vector pelletMap; //gameplay info (speeds, scores, etc.) }; #endif