fixed memory leak when starting a new game