random number and new game function