Made arrays sent as each individual one and some more minor changes.