making a global time reset function