okay TONS of changing for code quality; var renaming touched a lot of the files