Adventure Creator  1.66.1
An adventure game toolkit for Unity, by Chris Burton, ICEBOX Studios 2013-2018
AC.OptionsFileHandler_PlayerPrefs Class Reference
Inheritance diagram for AC.OptionsFileHandler_PlayerPrefs:
AC.iOptionsFileHandler

Public Member Functions

void SaveOptions (int profileID, string dataString, bool showLog)
 Saves the OptionsData, serialized as a string, to disk. More...
 
string LoadOptions (int profileID, bool showLog)
 Loads the OptionsData, serialized as a string, from disk. More...
 
void DeleteOptions (int profileID)
 Deletes the saved OptionsData string for a given profile. More...
 
int GetActiveProfile ()
 Returns the active profile ID number, if profiles are enabled More...
 
void SetActiveProfile (int profileID)
 Records the active profile ID More...
 
bool DoesProfileExist (int profileID)
 Checks if OptionsData for a given profile is stored More...
 

Member Function Documentation

◆ DeleteOptions()

void AC.OptionsFileHandler_PlayerPrefs.DeleteOptions ( int  profileID)

Deletes the saved OptionsData string for a given profile.

Parameters
profileIDThe ID number of the profile to delete</parm>

Implements AC.iOptionsFileHandler.

◆ DoesProfileExist()

bool AC.OptionsFileHandler_PlayerPrefs.DoesProfileExist ( int  profileID)

Checks if OptionsData for a given profile is stored

Parameters
profileIDThe ID number of the profile to check for</parm>
Returns
True if OptionsData for the given profile exists

Implements AC.iOptionsFileHandler.

◆ GetActiveProfile()

int AC.OptionsFileHandler_PlayerPrefs.GetActiveProfile ( )

Returns the active profile ID number, if profiles are enabled

Returns
The ID number of the active profile, or 0 if profiles are not enabled.

Implements AC.iOptionsFileHandler.

◆ LoadOptions()

string AC.OptionsFileHandler_PlayerPrefs.LoadOptions ( int  profileID,
bool  showLog 
)

Loads the OptionsData, serialized as a string, from disk.

Parameters
profileIDThe ID number of the profile to be loaded, or 0 if profiles are not enabled
Returns
The OptionsData, serialized as a string

Implements AC.iOptionsFileHandler.

◆ SaveOptions()

void AC.OptionsFileHandler_PlayerPrefs.SaveOptions ( int  profileID,
string  dataString,
bool  showLog 
)

Saves the OptionsData, serialized as a string, to disk.

Parameters
profileIDThe ID number of the profile to be saved, or 0 if profiles are not enabled
dataStringThe serialized data to save
showLogIf True, a Console message upon succesful saving is requested

Implements AC.iOptionsFileHandler.

◆ SetActiveProfile()

void AC.OptionsFileHandler_PlayerPrefs.SetActiveProfile ( int  profileID)

Records the active profile ID

Parameters
profileIDThe ID number of the profile to set as active</parm>

Implements AC.iOptionsFileHandler.