Refactor timer updating

Put the timer manipulation in a method.
Also check if timer exists in case the user calls render before start.