Exemplo n.º 1
0
        private void FillProgressBottomBar(UIElement container)
        {
            UIText uiText = new UIText("", 0.8f, false);

            uiText.HAlign             = 0.0f;
            uiText.VAlign             = 1f;
            uiText.TextOriginX        = 0.0f;
            this._progressPercentText = uiText;
            UIColoredSliderSimple coloredSliderSimple1 = new UIColoredSliderSimple();

            coloredSliderSimple1.Width       = new StyleDimension(0.0f, 1f);
            coloredSliderSimple1.Height      = new StyleDimension(15f, 0.0f);
            coloredSliderSimple1.VAlign      = 1f;
            coloredSliderSimple1.FilledColor = new Color(51, 137, (int)byte.MaxValue);
            coloredSliderSimple1.EmptyColor  = new Color(35, 43, 81);
            coloredSliderSimple1.FillPercent = 0.0f;
            UIColoredSliderSimple coloredSliderSimple2 = coloredSliderSimple1;

            coloredSliderSimple2.OnUpdate += new UIElement.ElementEvent(this.ShowStats_Completion);
            this._unlocksProgressBar       = coloredSliderSimple2;
            container.Append((UIElement)coloredSliderSimple2);
        }
Exemplo n.º 2
0
        private void FillProgressBottomBar(UIElement container)
        {
            UIText uIText = (_progressPercentText = new UIText("", 0.8f)
            {
                HAlign = 0f,
                VAlign = 1f,
                TextOriginX = 0f
            });
            UIColoredSliderSimple uIColoredSliderSimple = new UIColoredSliderSimple
            {
                Width       = new StyleDimension(0f, 1f),
                Height      = new StyleDimension(15f, 0f),
                VAlign      = 1f,
                FilledColor = new Color(51, 137, 255),
                EmptyColor  = new Color(35, 43, 81),
                FillPercent = 0f
            };

            uIColoredSliderSimple.OnUpdate += ShowStats_Completion;
            _unlocksProgressBar             = uIColoredSliderSimple;
            container.Append(uIColoredSliderSimple);
        }