From b74611d2b20fc071b8a699f2ce25e61f60118d6e Mon Sep 17 00:00:00 2001 From: HampusM Date: Sun, 22 May 2022 23:13:29 +0200 Subject: refactor: improve input handling & remove commands --- src/interfaces/game.hpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/interfaces/game.hpp') diff --git a/src/interfaces/game.hpp b/src/interfaces/game.hpp index a54782a..3aac6a9 100644 --- a/src/interfaces/game.hpp +++ b/src/interfaces/game.hpp @@ -2,12 +2,12 @@ #include "interfaces/command.hpp" #include "interfaces/cursor.hpp" +#include "interfaces/input.hpp" #include "interfaces/scene.hpp" #include #include -#include // NOLINTNEXTLINE(cppcoreguidelines-special-member-functions) class IGame @@ -20,11 +20,9 @@ public: virtual void on_update() noexcept = 0; virtual void on_exit() const noexcept = 0; - - [[nodiscard]] virtual auto get_input_config() const noexcept - -> std::unordered_map> = 0; }; using IGameFactory = yacppdic::Factory( const std::shared_ptr &scene, - const std::shared_ptr &cursor_controller)>; + const std::shared_ptr &cursor_controller, + const std::shared_ptr user_input_observer)>; -- cgit v1.2.3-18-g5258