More comments

Added a bunch of comments to uncommented sections of code.