Пример #1
0
    void Start()
    {
        _transform = GetComponent <RectTransform>();
        controller = GetComponentInParent <LegendaController>();

        Initialize();
    }
    public void Start()
    {
        //retrieve controller
        controller = GetComponentInParent <LegendaController>();

        //get components
        _transform = GetComponent <RectTransform>();
        _Image     = GetComponent <Image>();

        //get and set properties
        AdvancedUI.SetUIProperties(_transform, tabProperties);

        GameObject go = new GameObject();

        legendaTabPrefab = go.AddComponent <RectTransform>();

        icons  = new Image[controller.Amount];
        labels = new Text[controller.Amount];

        Initialize();
    }