Ejemplo n.º 1
0
        /// <summary>
        /// </summary>
        private void CreateBackground()
        {
            var container = new Container(0, 0, Width, 176)
            {
                Parent    = this,
                Alignment = Alignment.TopCenter
            };

            container.AddBorder(Color.White, 2);
            container.Border.Alpha = 1;

            Mask = new SpriteMaskContainer
            {
                Parent    = container,
                Size      = new ScalableVector2(Width - 4, 172),
                Alignment = Alignment.TopCenter,
                Tint      = Color.Black,
                Y         = 2
            };

            Background = new Sprite
            {
                Parent = container,
                Size   = new ScalableVector2(WindowManager.Width / 1.6f, WindowManager.Height / 1.6f),
                Image  = UserInterface.MenuBackground,
                Y      = -100,
                X      = -100
            };

            Mask.AddContainedSprite(Background);
        }