public void Start() { if (!errorUIAwake) { Awake(); } //Get External Interfaces errorHandler = interfaceFactory.ErrorHandler; uiManager = interfaceFactory.UIManager; //UI Manager is optional if (errorHandler == null) { gameObject.SetActive(false); } else { if (componentMissing) { errorHandler.EmergencyExit("Error UI component missing"); } else { errorUIStarted = true; } } }
public void setErrorMessage(string message) { if (!errorUIStarted) { Start(); } if (errorMessage != null) { errorMessage.text = message; } else { errorHandler.EmergencyExit("Error Message componenent missing"); } }