void Start() { if (PlayerPrefs.HasKey("Current_Narr_Prog")) { int currProg = PlayerPrefs.GetInt("Current_Narr_Prog"); currentProgress = (NarrativeProgress)currProg; SetWorldToNarrativeProgress(); } }
public void EndCurrentEvent() { if (currentEventRef != null) { if (currentEventRef.progressEvent != NarrativeProgress.None) { if ((int)currentEventRef.progressEvent > (int)currentProgress) { currentProgress = currentEventRef.progressEvent; PlayerPrefs.SetInt("Current_Narr_Prog", (int)currentProgress); SetWorldToNarrativeProgress(); } } currentEventRef.EndEvent(); currentEventRef = null; eventInteractionPanel.SetActive(false); } }