Suppose I have a simple game model (designed with MVC pattern): There is a World, there is a WorldRenderer and there is a GameController.
Now, World is a model of the world, i.e. game state. WorldRenderer holds a reference to the world, and its responsibility is just to draw the game state on the screen. GameController receives user input, updates the model and calls to renderer.
And here is a question: When and how do I draw all the stuff related to input?
For example, the game is to drag the box from one place to other, and there are just two places on the screen where the box can be located. At the beginning, the box is located at first legal place. The player drags the box from the first place to random place on the game screen (illegal place).
I still want to draw a box dragged to this place, and also I want to draw a line between last legal position of the box and current position of the box (under the cursor). Then, when the player releases the mouse button I want to actually change the game state (move the box back to its first position if it was above illegal one, or place it at the second legal position if the box was above it).
The game logic is pretty simple - process the input, see what are new coordinates of the box, and decide whether we should move the box to second legal location or to leave it at its current location (if the input is illegal) when the player releases a mouse button.
Now, drawing the dragged box and the line described above is just a visual improvement - to let the player see where he drags the box. It seems wrong to draw it in WorldRenderer, because in this case WorldRenderer should know about user input, and I want him to know only World. In addition it seems wrong to add additional information to World since this information is only used to improve user visual experience.
So what I supposed to do?