Added timer tick, and added functions to buttons