How can I save the Audio Volume

I used the unreal tounament’s code to save the Sound classes’ volume***(tested both Editor and Packaged game)***

FAudioDevice* AudioDevice = GEngine->AudioDevice;
		if (AudioDevice != NULL)
			for (TMap<USoundClass*, FSoundClassProperties>::TIterator It(AudioDevice->SoundClasses); It; ++It)
				USoundClass* ThisSoundClass = It.Key();
				if (ThisSoundClass != NULL && ThisSoundClass->GetFullName().Find(SoundClassName) != INDEX_NONE)
					// the audiodevice function logspams for some reason
					//AudioDevice->SetClassVolume(ThisSoundClass, NewVolume);
					ThisSoundClass->Properties.Volume = NewVolume;

it worked to changed the audio Volume.
but if I close the editor or packaged game. it will return to a default audio Volume every times.

I did the saving in the game setting class too. but it still not work.

it saved like following way


Have a look at the UGameUserSettings class. I havent got a chance to look into it further but from the description, this is where I was planning on implementing that.


  • Stores user settings for a game (for example graphics and sound settings), with the ability to save and load to and from a file.

I did not find any setttings stuff for audio or sound

I had the same problem and I solved it with a custom UGameUserSettings class. Take a look at our cheat-sheet at “Engine Core” → “Options Menu”.

I tried use this metod but i still have the same problem of the OP, any idea?