#ifndef KEYS_H #define KEYS_H #include #include "utils/Types.h" struct Keys final { int add(int glfwKey); bool isDown(uint key) const; uint getDownTime(uint key) const; void release(int glfwKey); void press(int glfwKey); void tick(); private: uint searchKey(int glfwKey) const; uint getIndex(uint key) const; struct Key { Key(); int glfwKey; bool down; uint downTime; }; std::array keys; }; #endif