Fixed movement functions.  Comments in code explain bugs and changes.