diff options
author | HampusM <hampus@hampusmat.com> | 2022-03-20 13:17:16 +0100 |
---|---|---|
committer | HampusM <hampus@hampusmat.com> | 2022-06-13 17:56:56 +0200 |
commit | 78f5d8cf644383adf20933ad64c160c07c2c54fb (patch) | |
tree | 2a348d90f8f150665c379bf2f3741731999dd679 /src/interfaces/game.hpp | |
parent | b6061eff99907495de282f611e8389e6468a1fb0 (diff) |
refactor: improve input configuring structure
Diffstat (limited to 'src/interfaces/game.hpp')
-rw-r--r-- | src/interfaces/game.hpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/interfaces/game.hpp b/src/interfaces/game.hpp index 3f9d735..cfff8c5 100644 --- a/src/interfaces/game.hpp +++ b/src/interfaces/game.hpp @@ -1,6 +1,12 @@ #pragma once +#include "interfaces/command.hpp" +#include "interfaces/cursor.hpp" +#include "interfaces/scene.hpp" +#include "interfaces/window.hpp" + #include <memory> +#include <unordered_map> class IGame { @@ -8,6 +14,11 @@ public: virtual ~IGame() = default; virtual void run() = 0; + + [[nodiscard]] virtual std::unordered_map<char, std::shared_ptr<ICommand>> + get_input_config( + const std::shared_ptr<IWindow> &window, const std::shared_ptr<IScene> &scene, + const std::shared_ptr<ICursorController> &cursor_controller) const noexcept = 0; }; using IGameFactory = std::shared_ptr<IGame> (*)(); |