diff options
author | WBoerenkamps <wrj.boerenkamps@student.avans.nl> | 2024-12-14 12:38:22 +0100 |
---|---|---|
committer | WBoerenkamps <wrj.boerenkamps@student.avans.nl> | 2024-12-14 12:38:22 +0100 |
commit | ccbfb97a11cd931655f2762443ffc36f5f25e86f (patch) | |
tree | 7ac5eae85844ab177e21e3033d26ffc738e06ad5 /src/crepe/api/Script.h | |
parent | a03f90fa9bcbd5a0c5b5d1f2e50df183c7c3640c (diff) |
removed sdlcontext from header and implemented initiliser list for EventData
Diffstat (limited to 'src/crepe/api/Script.h')
-rw-r--r-- | src/crepe/api/Script.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/crepe/api/Script.h b/src/crepe/api/Script.h index 668e5d1..4fbf344 100644 --- a/src/crepe/api/Script.h +++ b/src/crepe/api/Script.h @@ -6,6 +6,7 @@ #include "../manager/Mediator.h" #include "../system/CollisionSystem.h" #include "../types.h" +#include "../api/KeyCodes.h" #include "../util/OptionalRef.h" namespace crepe { @@ -134,7 +135,14 @@ protected: //! Retrieve SaveManager reference SaveManager & get_save_manager() const; - + /** + * \brief Utility function to retrieve the keyboard state + * \see SDLContext::get_keyboard_state + * + * \return current keyboard state map with Keycode as key and bool as value(true = pressed, false = not pressed) + * + */ + const keyboard_state_t& get_keyboard_state() const; //! \} private: |