void Start() { if (Instance == null) { Instance = this; } MessagesManager.RegisterShowMessage(ShowMessage); if (popUp == null) { popUp = (GameObject)Instantiate(popUpPrefab); popUp.transform.SetParent(hud.transform, false); popUp.SetActive(false); popUp.name = "PopUp"; } }