When you’re switching between levels, the widget will get destroyed. So as you’ve already noticed, the values are reset to default since a new widget is being created. However, you can store the main menu slider info before opening a new level, to retrieve them later & set the default values for the sliders when you go back to main menu again.
This can be done in two ways depending upon whether you want the values to remain the same across multiple sessions (quitting and restarting) of the game vs just your current game session.
If you want the values to remain even after quitting & restarting the game, then you can use the **SaveGame **object to store info in your hard drive.
If on the other hand, it’s only relevant within the current session, the **GameInstance **class is your friend since it will not get destroyed when you switch between levels. As a result, any values stored here (say for example the slider percent) will be available for you to access even after you leave the main menu & return to it later.