Preparing to save and load the game state.