]> git.localhorst.tv Git - blank.git/blobdiff - src/interface.hpp
extracted configuration of various parts
[blank.git] / src / interface.hpp
index ed417086504a8f8b86d97f648abe4349d3692e83..7bfd7155cc3823e335fd7d0cf69964a2121fbfbc 100644 (file)
@@ -18,7 +18,17 @@ class World;
 class Interface {
 
 public:
-       explicit Interface(World &);
+       struct Config {
+               float move_velocity = 0.005f;
+               float pitch_sensitivity = -0.0025f;
+               float yaw_sensitivity = -0.001f;
+
+               bool keyboard_disabled = false;
+               bool mouse_disabled = false;
+               bool visual_disabled = false;
+       };
+
+       Interface(const Config &, World &);
 
        void Handle(const SDL_KeyboardEvent &);
        void Handle(const SDL_MouseMotionEvent &);
@@ -26,10 +36,18 @@ public:
        void Handle(const SDL_MouseWheelEvent &);
        void Handle(const SDL_WindowEvent &);
 
+       void FaceBlock();
+       void TurnBlock();
+
        void PickBlock();
        void PlaceBlock();
        void RemoveBlock();
 
+       void PrintBlockInfo();
+       void PrintLightInfo();
+       void PrintSelectionInfo();
+       void Print(const Block &);
+
        void SelectNext();
        void SelectPrevious();
 
@@ -49,9 +67,7 @@ private:
        OutlineModel outline;
        glm::mat4 outline_transform;
 
-       float move_velocity;
-       float pitch_sensitivity;
-       float yaw_sensitivity;
+       Config config;
 
        Block remove;
        Block selection;