Exemplo n.º 1
0
        public void UpdateColors()
        {
            var colors = TeamsColorManager.Instance().GetColors(totalCount + 1);

            foreach (var pair in teamsToInfos)
            {
                pair.Value.SetColor(colors[pair.Key]);
            }
        }
Exemplo n.º 2
0
        private void Start()
        {
            var matchModel = MyMatchDataStorage.Instance.GetMatchModel();
            var models     = matchModel.PlayerModels;
            var colors     = TeamsColorManager.Instance().GetColors(models.Length + 1);

            for (var i = 0; i < models.Length; i++)
            {
                var model = models[i];
                var info  = Instantiate(prototype, transform);
                info.SetInfo(model);
                info.SetColor(colors[i + 1]);
            }
        }