Exemplo n.º 1
0
        public override ButtonController[] CreateButtons(int parentId)
        {
            int size = groupsDataInitializer.Data.Groups.Length;

            ButtonController[] result = new ButtonController[size];

            for (int i = 0; i < size; i++)
            {
                GameObject instance = CreateButton();

                GroupData         groupData    = groupsDataInitializer.Data.Groups[i];
                GroupProgressData progressData = progressController.GetGroupData(i);

                GroupButtonController buttonController = instance.GetComponent <GroupButtonController>();
                buttonController.Init(i, themeController.GetCurrentTheme(), groupData, progressData);
                result[i] = buttonController;
            }

            return(result);
        }
Exemplo n.º 2
0
        private void ProcessThemeUpdated()
        {
            ThemeData data = themeController.GetCurrentTheme();

            if (musicSource.clip != data.Music.AudioClip)
            {
                musicSource.volume = data.Music.Volume;
                musicSource.clip   = data.Music.AudioClip;
                musicSource.Play();
            }
        }
Exemplo n.º 3
0
 protected Color GetColor()
 {
     return(controller.GetCurrentTheme().GetColor(colorType));
 }