// Update is called once per frame void Update() { if (currentNumberOfEntries < totalNumberOfEntries) { timer -= Time.deltaTime; if (timer <= 0f) { for (int i = 0; i < totalNumberOfEntries; i++) { if (!infoPanel[i].GetComponent <InformationPanel>().InUse) { int openPanel = i; InformationPanel informationPanel = infoPanel[openPanel].GetComponent <InformationPanel>(); infoPanel[openPanel].GetComponent <CanvasGroup>().alpha = 1; informationPanel.GenerateInformationPanel(); currentNumberOfEntries++; timer = generateTime; break; } } } } }