void Start() { if (IsIndestructible) { DontDestroyOnLoad(gameObject); } ActionsQueue = new ActionsQueue(QueueName, true); StartCoroutine(ActionsQueue.ProcessQueue()); }
public ActionsQueue(string name = "Default queue", bool isStatic = false) { IsStatic = isStatic; Name = name; if (isStatic) { Instance = this; } }
void Start() { if (Instance == null) { Instance = this; } else { Destroy(gameObject); return; } LoadBundlesQueue = new ActionsQueue(); StartCoroutine(LoadBundlesQueue.ProcessQueue()); }
public void Start() { if (Instance == null) { Instance = this; } else { Destroy(gameObject); return; } ActionsQueue = new ActionsQueue(); StartCoroutine(ActionsQueue.ProcessQueue()); if (!IsObserverMode) { ActionsQueue.AddAction(new PlayGame()); } }