Okay, a well-meant advice: before you drown yourself in unnecessarily complex designs, you should first start with the most simple and straightforward approach, possible. You will be amazed by how far you can get by keeping things simple and solving problems in the most simple way once you encounter them.
Developing software by following designs you've merely read about, is going to make things much more difficult for you.
I'm asking you to start simple and, in a way, just make mistakes and learn from them.
No one will come up with a design that is just right from the beginning. Things evolve.
I know. I've currently got a simple way to handle input, but I want to have a more component based way to handle things.
The problem is just... I've only know how to do it the default way in GLFW with having one method in one class handling the input for everything.
Like this is my current way of handling things:
glfwSetKeyCallback(this.window, this.keyCallback = GLFWKeyCallback.create((window, key, scancode, action, mods) -> { this.onKey(key, action); } ));
But this approach is very limited, especially when working with multiply people on the project who do not all know about input handling or graphics etc.
The picture I posted in the last post is basically an example which actually shows a bit of what was described in the book I'm reading and it's quite easy to implement..
Just one interface or abstract class with an updateInput method and classes for everything which needs an input. This classes override the updateInput method and fill it with
actual content, like if(key W is pressed -> player move forward).
So basically like described above, GLFW docs teach you how to do it the way I'm currently doing it, but not how to get it working the way I want. Without LWJGL 3 and GLFW, so with plane Java Graphics classes and stuff I would direclty know I have to register the input handler that way to do it... but with GLFW.... no clue...
And yeah... things evovle... better not to ask how often I re-wrote parts of my code or the entire code base...