]> git.localhorst.tv Git - blank.git/blobdiff - src/interface.hpp
remove move branching from interface
[blank.git] / src / interface.hpp
index d3d58e8470b4fb9c9883e364917831ceaffe8bdd..1f4bb9034baf8028a2bb0dd4386ea6165d40d92b 100644 (file)
@@ -8,6 +8,7 @@
 #include "shader.hpp"
 
 #include <SDL.h>
+#include <glm/glm.hpp>
 
 
 namespace blank {
@@ -18,7 +19,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 &);
@@ -34,6 +45,7 @@ public:
        void RemoveBlock();
 
        void PrintBlockInfo();
+       void PrintChunkInfo();
        void PrintLightInfo();
        void PrintSelectionInfo();
        void Print(const Block &);
@@ -57,14 +69,12 @@ private:
        OutlineModel outline;
        glm::mat4 outline_transform;
 
-       float move_velocity;
-       float pitch_sensitivity;
-       float yaw_sensitivity;
+       Config config;
 
        Block remove;
        Block selection;
 
-       bool front, back, left, right, up, down;
+       glm::tvec3<int> fwd, rev;
 
 };