示例#1
0
    void Start()
    {
        savePointManager = GameObject.FindGameObjectWithTag("SavePointManager").GetComponent <SavePointManager>();

        con.color   = new Color32(0, 0, 0, 255);
        res.color   = new Color32(0, 0, 0, 255);
        theck.color = new Color32(0, 0, 0, 255);
        map.color   = new Color32(0, 0, 0, 255);
    }
示例#2
0
 public static void StopFlow(SceneTrans_SO __sceneTrans)
 {
     if (state == FlowState.Stopped)
     {
         return;
     }
     // save data
     SavePointManager.SaveSavePoint();
     SceneDirector.LoadScene("Main_Scene", __sceneTrans);
     state = FlowState.Stopped;
 }
示例#3
0
        public static void StartFlow(SceneTrans_SO __sceneTrans) // initiate flow only
        {
            // start flow
            if (state != FlowState.Stopped)
            {
                return;
            }

            // check whether have save point
            if (SavePointManager.IsSavePointSaved())
            {
                // load to save point
                SavePoint savePoint = SavePointManager.GetSavedSavePoint();
                IntraTransition.To(savePoint.scene, savePoint.markName, __sceneTrans);
            }
            else
            {
                // load to preface
                SceneDirector.LoadScene("Preface_Scene", __sceneTrans);
            }
        }
示例#4
0
 private void OnApplicationQuit()
 {
     SavePointManager.SaveSavePoint();
 }
 private void Start()
 {
     manager   = GameObject.FindWithTag("SavePointManager").GetComponent <SavePointManager>();
     triggered = false;
 }