Right now, in GameEngine, there's a UserInput method used to parse the input commands.
We should separate this into its own class.
I was thinking about a map of function pointers for the different actions. The class would parse the input, if it matches a known command, it triggers the function, passing its arguments if needed. But I'm open for your suggestions !
Right now, in GameEngine, there's a UserInput method used to parse the input commands.
We should separate this into its own class.
I was thinking about a map of function pointers for the different actions. The class would parse the input, if it matches a known command, it triggers the function, passing its arguments if needed. But I'm open for your suggestions !