I need to correct keyboard input so that it is accepted always not only when the move has just been finished.