Пример #1
0
        public override void DrawRecursive(Display display)
        {
            if (Advancement is Achievement && scale == 2)
            {
                if ((Advancement as Achievement).CanBeDoneYet)
                {
                    icon?.SetTint(Color.White);
                    frame?.SetTint(Color.White);
                    label?.SetTextColor(MainSettings.Instance.TextColor);
                }
                else
                {
                    icon?.SetTint(Color.Gray * 0.1f);
                    frame?.SetTint(Color.Gray * 0.2f);
                    label?.SetTextColor(MainSettings.Instance.TextColor * 0.5f);
                }
            }

            frame?.DrawRecursive(display);
            if (IsCompleted && MainSettings.Instance.RenderCompletionGlow)
            {
                display.Draw("frame_glow", frame.Center.ToVector2(), glowRotation, Color.White, Layer.Glow);
            }

            icon?.DrawRecursive(display);
            label?.DrawRecursive(display);
        }
Пример #2
0
        public override void DrawRecursive(Display display)
        {
            if (IsCollapsed)
            {
                return;
            }

            frame?.DrawRecursive(display);
            if (itemCount?.IsEstimate ?? false)
            {
                float opacity = (float)itemCount.PickedUp / itemCount.TargetCount;
                if (frame != null)
                {
                    frame.DrawThis(display);
                    display.Draw(Statistic.FRAME_COMPLETE, frame.ContentRectangle, Color.White * opacity);
                }

                if (IsCompleted && MainSettings.Instance.RenderCompletionGlow)
                {
                    display.Draw("frame_glow", frame.Center.ToVector2(), glowRotation, Color.White * opacity, Layer.Glow);
                }
            }
            else
            if (IsCompleted && MainSettings.Instance.RenderCompletionGlow)
            {
                display.Draw("frame_glow", frame.Center.ToVector2(), glowRotation, Color.White, Layer.Glow);
            }

            icon?.DrawRecursive(display);
            label?.DrawRecursive(display);
        }