refactored out repeated code
added 'tags' file to .gitignore
slight bug fixes to the way movement is calculated and the way buttons are updated