#pragma once #include "olcPixelGameEngine.h" #include //Future-proof game controller support. enum InputType{ KEY, MOUSE, CONTROLLER }; //A generic class that represents any type of input. class Input{ friend class InputGroup; InputType type; int key; //This will be interpreted differently depending on input type. public: Input(InputType type,int key); bool Pressed(); bool Held(); bool Released(); std::string GetDisplayName(); bool operator<(const Input&rhs)const{ return typekeys; public: InputGroup(); void AddKeybind(Input bind); void RemoveKeybind(Input bind); bool Pressed(); bool Held(); bool Released(); std::string GetDisplayName(); }; class GenericKey{ public: static std::map,std::string>keyLiteral; //The displayed text for a given key for a given input type. };