X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;ds=inline;f=src%2Fstandalone%2FPreloadState.hpp;fp=src%2Fstandalone%2FPreloadState.hpp;h=8dcd7060934e1c45bbdef70c5faebcdaf6b1378f;hb=e1209ec25c4cc91e13889876106f56bd51aa96e2;hp=0000000000000000000000000000000000000000;hpb=419c353301a3935be799f261cde9695043e09915;p=blank.git diff --git a/src/standalone/PreloadState.hpp b/src/standalone/PreloadState.hpp new file mode 100644 index 0000000..8dcd706 --- /dev/null +++ b/src/standalone/PreloadState.hpp @@ -0,0 +1,42 @@ +#ifndef BLANK_STANDALONE_PRELOADSTATE_HPP_ +#define BLANK_STANDALONE_PRELOADSTATE_HPP_ + +#include "../app/State.hpp" + +#include "../ui/Progress.hpp" + +#include + + +namespace blank { + +class ChunkLoader; +class ChunkRenderer; +class Environment; + +namespace standalone { + +class PreloadState +: public State { + +public: + PreloadState(Environment &, ChunkLoader &, ChunkRenderer &); + + void Handle(const SDL_Event &) override; + void Update(int dt) override; + void Render(Viewport &) override; + +private: + Environment &env; + ChunkLoader &loader; + ChunkRenderer &render; + Progress progress; + std::size_t total; + std::size_t per_update; + +}; + +} +} + +#endif