added return to "rest" function, (maybe) found a bug in manual movement