1 #ifndef BLANK_UI_INTERFACE_HPP_
2 #define BLANK_UI_INTERFACE_HPP_
5 #include "../app/FPSController.hpp"
6 #include "../app/IntervalTimer.hpp"
7 #include "../graphics/Font.hpp"
8 #include "../model/geometry.hpp"
9 #include "../model/OutlineModel.hpp"
10 #include "../world/Block.hpp"
13 #include <glm/glm.hpp>
21 class DirectionalLighting;
29 float move_velocity = 0.005f;
30 float pitch_sensitivity = -0.0025f;
31 float yaw_sensitivity = -0.001f;
33 bool keyboard_disabled = false;
34 bool mouse_disabled = false;
35 bool visual_disabled = false;
38 Interface(const Config &, const Assets &, const FrameCounter &, World &);
40 void HandlePress(const SDL_KeyboardEvent &);
41 void HandleRelease(const SDL_KeyboardEvent &);
42 void Handle(const SDL_MouseMotionEvent &);
43 void HandlePress(const SDL_MouseButtonEvent &);
44 void HandleRelease(const SDL_MouseButtonEvent &);
45 void Handle(const SDL_MouseWheelEvent &);
46 void Handle(const SDL_WindowEvent &) noexcept;
51 void ToggleCollision();
55 void RemoveBlock() noexcept;
57 void PrintBlockInfo();
58 void PrintChunkInfo();
59 void PrintLightInfo();
60 void PrintSelectionInfo();
61 void Print(const Block &);
64 void SelectPrevious();
71 void Render(DirectionalLighting &, BlendedSprite &) noexcept;
77 const FrameCounter &counter;
89 glm::mat4 outline_transform;
93 SpriteModel counter_sprite;
94 glm::mat4 counter_transform;
95 SDL_Color counter_color;
99 IntervalTimer place_timer;
100 IntervalTimer remove_timer;
105 glm::tvec3<int> fwd, rev;