void Promote() { promotionHeader.text = "You've been promoted!"; string line = "You've been recognized for your efforts and have been promoted to the\n\n\n\nYou may stay and practice the ## protocol or you may advance to the next office."; string[] parts = certificateText.text.Split('\n'); string currentProtocol = parts[0]; string nextOfficeLocation = parts[1]; string staySubtextLine1 = parts[2]; string staySubtextLine2 = parts[3]; string staySubtextString = ""; Debug.Log(staySubtextLine2); if (!string.IsNullOrEmpty(staySubtextLine2)) { staySubtextString = staySubtextLine1 + "\n" + staySubtextLine2; } else { staySubtextString = staySubtextLine1; } string advanceSubtextLine1 = "Proceed To"; string advanceSubtextLine2 = nextOfficeLocation; string advanceSubtextString = ""; Debug.Log(advanceSubtextLine2); if (!string.IsNullOrEmpty(advanceSubtextLine2)) { advanceSubtextString = advanceSubtextLine1 + "\n" + advanceSubtextLine2; } else { advanceSubtextString = advanceSubtextLine1; } line = line.Replace("##", currentProtocol); promotionLocationText.text = nextOfficeLocation; staySubtext.text = staySubtextString; advanceSubtext.text = advanceSubtextString; promotionUI.SetAdvanceButtonText("Advance To " + nextOfficeLocation); promotionText.text = line; promotionUI.EnableUI(true, false); waitingToAdvance = true; SortingAttempt.Reset(); SetScore(); }