class InputDirection { bool up = false; bool down = false; bool left = false; bool right = false; /// reset all directions to false void reset() { up = false; down = false; left = false; right = false; } }