added initialization and updating for the all_time counter