Added time counter with some problems