Finished group parsing, organized a lot of code.