So in UE4.8.3 I am using the following C++ functions to change some screen settings, like resolution and fullscreen/windowed mode:
Settings->RequestResolutionChange(Width, Height, WindowMode, false);
Settings->ConfirmVideoMode();
Settings->SetScreenResolution(Settings->GetLastConfirmedScreenResolution());
Settings->SetFullscreenMode(Settings->GetLastConfirmedFullscreenMode());
Settings->SaveSettings();
This works for the running game, i.e. after calling these functions the screen is correctly set to the desired resolution etc. However, none of these settings are being written to a config (ini) file. In fact, there is no such ini file at all in the packaged game.
I found the ini file to be saved in the following folder: %LOCALAPPDATA%//Saved/Config/WindowsNoEditor/GameUserSettings.ini. However, after calling the C++ code shown above, this ini file becomes completely empty, no settings there. So after starting the packaged game again, obviously no settings set the last time are used (as the ini file is empty).
I am totally out of ideas now
Could someone please explain to me what I am doing wrong, and what I need to do in order to get this to work?