The difference between 'on time' and 'in time', when you are on time, it happens at the planned time, for example the flight is scheduled to leave at 10:30 AM (if it leaves at 10:30 AM, then the flight is leaving on time.
'In time' means when you are in time, you are early enough to spare time. For example, I arrived at 9:30 so i could have coffee before boarding the flight. i arrived in time to have some coffee before boarding the flight/plane.