Finished coilgun code, to be tested now