Exemplo n.º 1
0
 /*This method will automatically save a Tasks progress in PlayerPrefs - is used for when the task is completed or incomplete*/
 public static void TrackTaskProgress(Task TaskInProgress)
 {
     //get level/prison/task from level builder
     //task completed
     string Label = "P" + TaskInProgress.GetPrison() + "_" +
                     "L" + TaskInProgress.GetLevel() + "_" +
                     "PH" + TaskInProgress.GetPhase() + "_" +
                     "T" + TaskInProgress.GetOrder();
     int Progress = TaskInProgress.IsTaskCompleted() ? 1 : 0;
     PlayerPrefs.GetInt (Label);
     PlayerPrefs.SetInt(Label, Progress);
 }