Hey! So I decided I wanted to go ahead and implement a little thing to my Main Menu by only showing the Continue button when there is a save file (so it’s inactive on the first playthrough).
So what I did was, inside the saving wrapper, I added a GetSaveFileBool() function that returns a bool. Inside the function I just have it, simply, return SaveFileExists(GetCurrentSave);
Then, in the MainMenuUI, I put a SerializeField Button, and I added a Start function. Inside Start, I set the continue buttons game object to set active depending on the savingwrapper’s funciton that returns if there’s a save file. It now turns on and off the continue button depending on whether or not there’s a save file.
Here are my edits if anyone wants to use it!
Saving Wrapper:
public bool GetSaveFileBool()
{
return GetComponent<SavingSystem>().SaveFileExists(GetCurrentSave());
}
Main Menu UI:
[SerializeField] Button continueButton;
private void Start()
{
continueButton.gameObject.SetActive(savingWrapper.value.GetSaveFileBool());
}