Clean up initialization and update of tick counters.