Added lots of comments to mainScript.js, listing what needs to be done to that file.