private void BeforeDestroying()
 {
     if (unitySingletons != null)
     {
         GameObject.Destroy(unitySingletons);
     }
     _singletonFactory.Destroy();
 }
 private void BeforeDestroying()
 {
     if (unitySingletons != null)
     {
         if (!Application.isPlaying)
         {
             GameObject.DestroyImmediate(unitySingletons);
         }
         else
         {
             GameObject.Destroy(unitySingletons);
         }
     }
     _singletonFactory.Destroy();
 }
Ejemplo n.º 3
0
 public void CreateNewGame()
 {
     SingletonFactory <UserInfo> .Destroy();
 }