// Start is called before the first frame update
    void Start()
    {
        NotificationElement = defaultNotificationElement;

        variableEventSystem = GameObject.FindGameObjectWithTag("VariableEventSystem").GetComponent <VariableEventSystem>();

        notificationText = notificationUIGroup.GetComponentInChildren <Text>();
        portrait         = notificationUIGroup.GetComponentInChildren <Image>();
        rectTransform    = notificationUIGroup.GetComponent <RectTransform>();

        defaultHiddenPositionY = rectTransform.anchoredPosition.y;

        //Only for Debugging:
        //PopUpNotification(NotificationElement);
    }
Esempio n. 2
0
 void Start()
 {
     DontDestroyOnLoad(gameObject);
     variableEventSystem = GameObject.FindGameObjectWithTag("VariableEventSystem").GetComponent <VariableEventSystem>();
     variableEventSystem.WaitForInizialisation += SetVariables;
 }