Reworked code to use timers