Fixes #414 - integrates rubocop gem

Adds rubocop gem and fixes majority of issues noted by cop.
Why did you add the underscores here? This should be an integer.