Moved keyboard proocessing to engine