Exemple #1
0
    // Use this for initialization
    void Awake()
    {
        List <Template> allTemplates = new TemplateData().GetAllTemplates();

        allTemplates.ForEach(delegate(Template template)
        {
            TemplateViewContent templateViewContent = (TemplateViewContent)Instantiate(templatePrefab);
            templateViewContent.InitializeVariables(template);
            templateViewContent.transform.SetParent(scrollContent.transform, false);
        });
        scrollView.verticalNormalizedPosition = 1;
    }