added timer for controling game speed