Ejemplo n.º 1
0
 void OnDestroy()
 {
     if (inst)
     {
         inst = null;
     }
 }
Ejemplo n.º 2
0
 void Awake()
 {
     if (!inst)
     {
         inst = this;
     }
 }