Added functionality to save move count and score in text file