Пример #1
0
        /// <inheritdoc />
        /// <summary>
        /// </summary>
        public DrawableDifficulty(DifficultyScrollContainer container)
        {
            Container = container;

            Size  = new ScalableVector2(410, HEIGHT);
            Image = UserInterface.SelectButtonBackground;

            DifficultyName = new SpriteText(Fonts.Exo2SemiBold, " ", 13)
            {
                Parent   = this,
                Position = new ScalableVector2(15, 12)
            };

            TextDifficultyRating = new SpriteText(Fonts.Exo2SemiBold, " ", 12)
            {
                Parent   = this,
                Position = new ScalableVector2(DifficultyName.X, DifficultyName.Y + DifficultyName.Height + 4),
                Tint     = ColorHelper.DifficultyToColor(19.12f)
            };

            Creator = new SpriteText(Fonts.Exo2SemiBold, " ", 10)
            {
                Parent    = this,
                Alignment = Alignment.TopRight,
                Position  = new ScalableVector2(-5, TextDifficultyRating.Y + TextDifficultyRating.Height + 3)
            };

            Clicked += OnClicked;
            ModManager.ModsChanged += OnModsChanged;
        }
Пример #2
0
        /// <inheritdoc />
        /// <summary>
        /// </summary>
        public DrawableDifficulty(DifficultyScrollContainer container)
        {
            Container = container;

            Size  = new ScalableVector2(410, HEIGHT);
            Image = UserInterface.SelectButtonBackground;

            DifficultyName = new SpriteTextBitmap(FontsBitmap.GothamRegular, " ")
            {
                Parent   = this,
                Position = new ScalableVector2(15, 12),
                FontSize = 18
            };

            TextDifficultyRating = new SpriteTextBitmap(FontsBitmap.GothamRegular, " ")
            {
                Parent   = this,
                Position = new ScalableVector2(DifficultyName.X, DifficultyName.Y + DifficultyName.Height + 4),
                Tint     = ColorHelper.DifficultyToColor(19.12f),
                FontSize = 16
            };

            Creator = new SpriteTextBitmap(FontsBitmap.GothamRegular, " ")
            {
                Parent    = this,
                Alignment = Alignment.TopRight,
                Position  = new ScalableVector2(-5, TextDifficultyRating.Y + TextDifficultyRating.Height + 6),
                FontSize  = 14
            };

            Clicked += OnClicked;
            ModManager.ModsChanged += OnModsChanged;
        }