Bug fixes, better looking bars, minor refactoring, added comments