private void DestroySingletons()
 {
     TNT.DestroySingleton();
     GameTimer.DestroySingleton();
     Keypad.DestroySingleton();
     KeypadPuzzle.DestroySingleton();
     GameTimer.DestroySingleton();
     Hints.DestroySingleton();
     TextManager.DestroySingleton();
     CommandConsole.DestroySingleton();
     ThoughtsManager.DestroySingleton();
 }
示例#2
0
 private void SpawnThought()
 {
     if (CurrentThoughtID == -1)
     {
         Debug.LogError("Error : Thought spawner doesn't know what to spawn!!");
     }
     else if (CurrentThoughtID >= RelatedThoughts.Length)
     {
         Debug.LogError("Error : Spawned thought out of bounds, caused by caller : " + GetCallerName());
     }
     else
     {
         ThoughtsManager.FireThought(RelatedThoughts[CurrentThoughtID]);
     }
 }
示例#3
0
 protected void DespawnThought()
 {
     //No need to despawn a thought if there's no active thought.
     if (CurrentThoughtID != -1)
     {
         if (CurrentThoughtID >= RelatedThoughts.Length)
         {
             Debug.LogError("Error : Despawned thought out of bounds, caused by caller : " + GetCallerName());
         }
         else
         {
             ThoughtsManager.DeleteThought(RelatedThoughts[CurrentThoughtID]);
         }
     }
 }
示例#4
0
 private void OnEnable()
 {
     Instance            = this;
     OnThoughtSpawned   += UpdateThought;
     OnThoughtDespawned += UpdateThought;
 }
示例#5
0
 public static void DestroySingleton()
 {
     Instance  = null;
     _instance = null;
 }
示例#6
0
 private void Awake()
 {
     _instance     = this;
     thoughtsColor = thoughtsText.color;
 }
 private void Start()
 {
     thoughtsManager = ThoughtsManager.Instance;
 }