Key Handling mechanics
- by Max
I am new to game development and am working on my first game using OpenGL and C++.
I have a game class which handles everything necessary in an update() function.
Now i want to handle keyboard inputs. I use GLFW which supports key callbacks. However i wonder how to deal with inputs. Should i record the keys pressed and poll on it the next time my game updates or should the callback immediately perform the necessary actions? And why?
Thanks :)