Updated how the csv output. Needs more testing, might add better csv library if testing doesnt go well