diff options
Diffstat (limited to 'src/game/game.hpp')
-rw-r--r-- | src/game/game.hpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/game/game.hpp b/src/game/game.hpp index fb2ad63..fb6a5ed 100644 --- a/src/game/game.hpp +++ b/src/game/game.hpp @@ -3,6 +3,7 @@ #include "interfaces/cursor.hpp" #include "interfaces/game.hpp" #include "interfaces/generation_tracker.hpp" +#include "interfaces/input.hpp" #include "interfaces/scene.hpp" #include "interfaces/status_manager.hpp" #include "interfaces/statusline_subscriber_adapter.hpp" @@ -18,6 +19,7 @@ public: std::shared_ptr<ICursorController> cursor_controller, std::shared_ptr<IGenerationTracker> generation_tracker, std::shared_ptr<IStatusManager> status_manager, + std::shared_ptr<IUserInputObserver> user_input_observer, IStatusLineSubscriberAdapterFactory<Vector2> vector2_statusline_subscriber_adapter_factory) noexcept; @@ -27,16 +29,16 @@ public: void on_exit() const noexcept override; - [[nodiscard]] auto get_input_config() const noexcept - -> std::unordered_map<char, std::shared_ptr<ICommand>> override; - private: std::shared_ptr<IScene> _scene; std::shared_ptr<ICursorController> _cursor_controller; std::shared_ptr<IGenerationTracker> _generation_tracker; std::shared_ptr<IStatusManager> _status_manager; + std::shared_ptr<IUserInputObserver> _user_input_observer; IStatusLineSubscriberAdapterFactory<Vector2> _vector2_statusline_subscriber_adapter_factory; std::chrono::system_clock::time_point _last_update_time; + + void _move_cursor(const Vector2 &direction) noexcept; }; |