I'm working on an input system (in C#) and now I'm wondering, what is the best place to put input functionality?
Currently what I was coding was a bunch of delegates which act as callbacks (i.e. onkeypress, onmouseclick, etc) and the idea is when the input manager checks for input it invokes these delegaetes.
However this means that input is updated when the input manager updates and not when a game class has its own update function called.
The way I see it is moving input functionality out of a classes update function and deferring them would forecefully reduce the codes complexity (particularly the update function) but on the other hand I'm thinking it might be a better idea to move update and input to the same place as it would give the coder more freedom to work with the input systems.
Anyone have any ideas on this matter?