X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fapp%2FAssets.hpp;h=3cfc1334371f7e2e491d3053113c6c0dd672a396;hb=5e82e61db8b9ed5b9a30c9706620b62b844ac734;hp=b95ee48ea4f75a615cbee85d93a83e5ace754f3a;hpb=ed63638006af93bf0cf010ed48706b893ac0da35;p=blobs.git diff --git a/src/app/Assets.hpp b/src/app/Assets.hpp index b95ee48..3cfc133 100644 --- a/src/app/Assets.hpp +++ b/src/app/Assets.hpp @@ -2,27 +2,43 @@ #define BLOBS_APP_ASSETS_HPP_ #include "../graphics/ArrayTexture.hpp" +#include "../graphics/CreatureSkin.hpp" #include "../graphics/PlanetSurface.hpp" #include "../graphics/SunSurface.hpp" +#include "../world/Resource.hpp" +#include "../world/Set.hpp" +#include "../world/TileType.hpp" #include namespace blobs { +namespace io { + class TokenStreamReader; +} namespace app { struct Assets { std::string path; + std::string data_path; + std::string skin_path; std::string tile_path; + struct { + world::Set resources; + world::Set tiles; + } data; + struct { graphics::ArrayTexture tiles; + graphics::ArrayTexture skins; } textures; struct { graphics::PlanetSurface planet_surface; graphics::SunSurface sun_surface; + graphics::CreatureSkin creature_skin; } shaders; Assets(); @@ -34,7 +50,11 @@ struct Assets { Assets(Assets &&) = delete; Assets &operator =(Assets &&) = delete; + void ReadResources(io::TokenStreamReader &); + void ReadTileTypes(io::TokenStreamReader &); + void LoadTileTexture(const std::string &name, graphics::ArrayTexture &, int layer) const; + void LoadSkinTexture(const std::string &name, graphics::ArrayTexture &, int layer) const; };