Exemplo n.º 1
0
 /// <summary>Checks if the Singleton instance exists.</summary>
 public static void CheckInstance()
 {
     if (Instance == null)
     {
         Instance = new GameObject("PasteManager").AddComponent <PasteManager>();
     }
 }
Exemplo n.º 2
0
 /// <summary>Checks if the Dispatcher instance exists and stores this class instance as the Singleton.</summary>
 protected virtual void Start()
 {
     Dispatcher.CheckInstance();
     PasteManager.CheckInstance();
     Instance = this;
 }