Beispiel #1
0
 public static void RegisterUnitySingleton <T>(T obj) where T : MonoBehaviour
 {
     UnitySingleton <T> .Register(obj);
 }
Beispiel #2
0
 public virtual void Awake()
 {
     UnitySingleton <T> .Register(this as T);
 }
Beispiel #3
0
 public static T GetUnitySingleton <T>() where T : MonoBehaviour
 {
     return(UnitySingleton <T> .Get());
 }