Inventory Engine v4.2
Loading...
Searching...
No Matches
MoreMountains.Tools.MMAchievementManager Class Reference

This static class is in charge of storing the current state of the achievements, unlocking/locking them, and saving them to data files. More...

Static Public Member Functions

static void LoadAchievementList (MMAchievementList achievementList)
 You'll need to call this method to initialize the manager.
static void UnlockAchievement (string achievementID)
 Unlocks the specified achievement (if found).
static void LockAchievement (string achievementID)
 Locks the specified achievement (if found).
static void AddProgress (string achievementID, int newProgress)
 Adds progress to the specified achievement (if found).
static void SetProgress (string achievementID, int newProgress)
 Sets the progress of the specified achievement (if found) to the specified progress.
static void ResetAchievements (string listID)
 Removes saved data and resets all achievements from a list.
static void ResetAllAchievements ()
static void LoadSavedAchievements ()
 Loads the saved achievements file and updates the array with its content.
static void SaveAchievements ()
 Saves the achievements current status to a file on disk.
static void FillSerializedMMAchievementManager (SerializedMMAchievementManager serializedAchievements)
 Serializes the contents of the achievements array to a serialized, ready to save object.
static void ExtractSerializedMMAchievementManager (SerializedMMAchievementManager serializedAchievements)
 Extracts the serialized achievements into our achievements array if the achievements ID match.

Static Public Attributes

static string _defaultFileName = "Achievements"
static string _saveFolderName = "MMAchievements/"
static string _saveFileExtension = ".achievements"
static string SaveFileName
static string ListID

Properties

static List< MMAchievementAchievementsList [get]

Detailed Description

This static class is in charge of storing the current state of the achievements, unlocking/locking them, and saving them to data files.

Member Function Documentation

◆ AddProgress()

void MoreMountains.Tools.MMAchievementManager.AddProgress ( string achievementID,
int newProgress )
static

Adds progress to the specified achievement (if found).

Parameters
achievementIDAchievement ID.
newProgressNew progress.

◆ ExtractSerializedMMAchievementManager()

void MoreMountains.Tools.MMAchievementManager.ExtractSerializedMMAchievementManager ( SerializedMMAchievementManager serializedAchievements)
static

Extracts the serialized achievements into our achievements array if the achievements ID match.

Parameters
serializedAchievementsSerialized achievements.

◆ FillSerializedMMAchievementManager()

void MoreMountains.Tools.MMAchievementManager.FillSerializedMMAchievementManager ( SerializedMMAchievementManager serializedAchievements)
static

Serializes the contents of the achievements array to a serialized, ready to save object.

Parameters
serializedInventorySerialized inventory.

◆ LoadAchievementList()

void MoreMountains.Tools.MMAchievementManager.LoadAchievementList ( MMAchievementList achievementList)
static

You'll need to call this method to initialize the manager.

◆ LoadSavedAchievements()

void MoreMountains.Tools.MMAchievementManager.LoadSavedAchievements ( )
static

Loads the saved achievements file and updates the array with its content.

◆ LockAchievement()

void MoreMountains.Tools.MMAchievementManager.LockAchievement ( string achievementID)
static

Locks the specified achievement (if found).

Parameters
achievementIDAchievement ID.

◆ ResetAchievements()

void MoreMountains.Tools.MMAchievementManager.ResetAchievements ( string listID)
static

Removes saved data and resets all achievements from a list.

Parameters
listIDThe ID of the achievement list to reset.

◆ ResetAllAchievements()

void MoreMountains.Tools.MMAchievementManager.ResetAllAchievements ( )
static

◆ SaveAchievements()

void MoreMountains.Tools.MMAchievementManager.SaveAchievements ( )
static

Saves the achievements current status to a file on disk.

◆ SetProgress()

void MoreMountains.Tools.MMAchievementManager.SetProgress ( string achievementID,
int newProgress )
static

Sets the progress of the specified achievement (if found) to the specified progress.

Parameters
achievementIDAchievement ID.
newProgressNew progress.

◆ UnlockAchievement()

void MoreMountains.Tools.MMAchievementManager.UnlockAchievement ( string achievementID)
static

Unlocks the specified achievement (if found).

Parameters
achievementIDAchievement I.

Member Data Documentation

◆ _defaultFileName

string MoreMountains.Tools.MMAchievementManager._defaultFileName = "Achievements"
static

◆ _saveFileExtension

string MoreMountains.Tools.MMAchievementManager._saveFileExtension = ".achievements"
static

◆ _saveFolderName

string MoreMountains.Tools.MMAchievementManager._saveFolderName = "MMAchievements/"
static

◆ ListID

string MoreMountains.Tools.MMAchievementManager.ListID
static

◆ SaveFileName

string MoreMountains.Tools.MMAchievementManager.SaveFileName
static

Property Documentation

◆ AchievementsList

List<MMAchievement> MoreMountains.Tools.MMAchievementManager.AchievementsList
staticget

The documentation for this class was generated from the following file: