Exemplo n.º 1
0
 public override void OnEnable()
 {
     base.OnEnable();
     SceneManager.sceneLoaded -= RecordCurrentScene;
     SceneManager.sceneLoaded += RecordCurrentScene;
     PersistentDataManager.RegisterPersistentData(gameObject);
 }
Exemplo n.º 2
0
 public void OnEnable()
 {
     // This optional code registers this GameObject with the PersistentDataManager.
     // One of the options on the PersistentDataManager is to only send notifications
     // to registered GameObjects. The default, however, is to send to all GameObjects.
     // If you set PersistentDataManager to only send notifications to registered
     // GameObjects, you need to register this component using the line below or it
     // won't receive notifications to save and load.
     PersistentDataManager.RegisterPersistentData(this.gameObject);
 }
Exemplo n.º 3
0
    public void OnDisable()
    {
        if (languageIsChosen)
        {
            languageIsChosenInt = 1;
        }
        else if (!languageIsChosen)
        {
            languageIsChosenInt = 0;
        }

        PersistentDataManager.RegisterPersistentData(this.gameObject);
    }
 public void OnEnable()
 {
     PersistentDataManager.RegisterPersistentData(this.gameObject);
 }
        void OnDisable()
        {
            OnRecordPersistentData();

            PersistentDataManager.RegisterPersistentData(this.gameObject);
        }
Exemplo n.º 6
0
 void OnDisable()
 {
     PersistentDataManager.RegisterPersistentData(this.gameObject);
 }
Exemplo n.º 7
0
 void OnEnable()
 {
     VariableName = name + transform.position.x.ToString("F2") + transform.position.ToString("F2");
     print(VariableName);
     PersistentDataManager.RegisterPersistentData(this.gameObject);
 }
Exemplo n.º 8
0
 public void OnEnable()
 {
     LevelName = GameManager.Instance.LevelName;
     PersistentDataManager.RegisterPersistentData(this.gameObject);
 }
Exemplo n.º 9
0
 public override void OnDisable()
 {
     base.OnDisable();
     PersistentDataManager.RegisterPersistentData(this.gameObject);
 }
 void OnDisable()
 {
     PersistentDataManager.RegisterPersistentData(this.gameObject);
     GameManager.OnSceneChanged  -= SceneChanged;
     GameManager.OnSceneUnloaded -= BeforeSceneChange;
 }
Exemplo n.º 11
0
 public void OnDisable()
 {
     // Unsubscribe the GameObject from PersistentDataManager notifications:
     PersistentDataManager.RegisterPersistentData(this.gameObject);
 }
 public override void OnEnable()
 {
     base.OnEnable();
     VariableName = name + transform.position.x.ToString("F2") + transform.position.ToString("F2");
     PersistentDataManager.RegisterPersistentData(this.gameObject);
 }