示例#1
0
 void OnDisable()
 {
     if (_current == this)
     {
         _current = null;
     }
 }
示例#2
0
 static public void Initialize()
 {
     if (!initialized)
     {
         if (!Application.isPlaying)
         {
             return;
         }
         initialized = true;
         var g = new GameObject("LoomOld");
         _current = g.AddComponent <LoomOld>();
         GameObject.DontDestroyOnLoad(g);
     }
 }
示例#3
0
 void Awake()
 {
     _current    = this;
     initialized = true;
 }