X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fstandalone%2FMasterState.hpp;h=26fcf26742a62cb4e05ca49208b5a9df5bc9ec63;hb=69e4d6c0a86a27f9b3f1297e46c55b36059a24b9;hp=f72c38ceed7b73f83059b3e1249c4da46f4c42f9;hpb=7e782291e0ce39eb2d4e8c1df28f682c313e6f8d;p=blank.git diff --git a/src/standalone/MasterState.hpp b/src/standalone/MasterState.hpp index f72c38c..26fcf26 100644 --- a/src/standalone/MasterState.hpp +++ b/src/standalone/MasterState.hpp @@ -7,14 +7,14 @@ #include "PreloadState.hpp" #include "UnloadState.hpp" #include "../ai/Spawner.hpp" +#include "../audio/SoundBank.hpp" #include "../graphics/SkyBox.hpp" -#include "../model/ModelRegistry.hpp" -#include "../model/ShapeRegistry.hpp" +#include "../shared/ChatState.hpp" +#include "../shared/WorldResources.hpp" #include "../ui/DirectInput.hpp" #include "../ui/HUD.hpp" #include "../ui/InteractiveManipulator.hpp" #include "../ui/Interface.hpp" -#include "../world/BlockTypeRegistry.hpp" #include "../world/ChunkIndex.hpp" #include "../world/ChunkLoader.hpp" #include "../world/ChunkRenderer.hpp" @@ -32,7 +32,8 @@ namespace standalone { class MasterState : public State -, public ClientController { +, public ClientController +, public ChatState::Responder { public: MasterState( @@ -47,6 +48,9 @@ public: void OnResume() override; void OnPause() override; + void OnFocus() override; + void OnBlur() override; + void Handle(const SDL_Event &) override; void Update(int dt) override; void Render(Viewport &) override; @@ -60,12 +64,13 @@ public: void SetDebug(bool) override; void Exit() override; + void OnLineSubmit(const std::string &) override; + private: Config &config; Environment &env; - ShapeRegistry shapes; - BlockTypeRegistry block_types; - ModelRegistry models; + WorldResources res; + SoundBank sounds; const WorldSave &save; World world; ChunkIndex &spawn_index; @@ -84,6 +89,7 @@ private: PreloadState preload; UnloadState unload; + ChatState chat; };