Changed updatetime function to match openmm 6 code