Exemple #1
0
        private void CreateMaterialButtons()
        {
            var            i = 0;
            MaterialWidget materialWidget;

            while ((materialWidget = MaterialWidget.Create(this, i)) != null)
            {
                if (!_editor.Materials.HasMaterial(i))
                {
                    i++;
                    continue;
                }

                _materialWidgets.Add(materialWidget);
                i++;
            }
        }
Exemple #2
0
        private void RefreshMaterialButtons()
        {
            var            i = 0;
            MaterialWidget materialWidget;

            while ((materialWidget = MaterialWidget.Create(this, i)) != null)
            {
                if (!_editor.Materials.HasMaterial(i))
                {
                    i++;
                    continue;
                }

                materialWidget.SetMaterial(_editor.Materials[i]);

                i++;
            }
        }