I am trying to create a BlueprintSetter using GConfig->SetBool but I’m not getting it to work.
This is my .H File
UFUNCTION(BlueprintSetter, meta = (DisplayName = "Set Start in VR"), Category = "name")
bool SetStartinVR();
This is my .CPP File
bool UBlueprints::SetStartinVR() {
//Set Start in VR
bool SetStartinVR;
GConfig->SetBool(
TEXT("/script/engineSettings.GeneralProjectSettings"),
TEXT("bStartinVR"),
SetStartinVR,
GGameIni
);
return SetStartinVR;
}
Can Someone please tell me what I’m doing wrong.