void DisplayNextStage() { currentStage++; delayer = 300; if (currentStage > stageCount) { if (readyToSolve) { return; } readyToSolve = true; ShowFinalStage(); if (wiresCut.Count() == 13) { Debug.LogFormat("[Forget Them All #{0}] All wires cut before module is ready to be solved. Autosolving. (Like, seriously?? 13 strikes and you're still alive? Jeez...)", moduleId); moduleSolved = true; GetComponent <KMBombModule>().HandlePass(); } CalcFinalSolution(); CalcWireOrder(); return; } foreach (GameObject LED in LEDs) { LED.transform.Find("light").GetComponentInChildren <Renderer>().material = lightColors[13]; } StageInfo s = stages[currentStage - 1]; Debug.LogFormat("[Forget Them All #{0}] --------------------------- Stage {1} ---------------------------", moduleId, currentStage); Debug.LogFormat("[Forget Them All #{0}] Stage {1} LED: {2}", moduleId, currentStage, s.GetOnLED()); for (int i = 0; i < s.LED.Count(); i++) { if (s.LED[i]) { LEDs[Array.IndexOf(colors, i)].GetComponentInChildren <Renderer>().material = lightColors[i]; } } String stageText = ""; if (currentStage < 100) { stageText += "0"; } if (currentStage < 10) { stageText += "0"; } stageText += currentStage + ""; stageNo.text = stageText; }