Beispiel #1
0
        public override void Draw(Scene scene)
        {
            int   x         = (int)Position.X - Width / 2;
            int   y         = (int)Position.Y - Height / 2;
            float openCoeff = Math.Min(Ticks / 7f, 1f);

            UI.Draw(FontRenderer, x, y, openCoeff);
            if (openCoeff >= 1)
            {
                scene.SpriteBatch.Draw(RenderTarget, new Rectangle(x, y, RenderTarget.Width, RenderTarget.Height), RenderTarget.Bounds, Color.White);
            }
        }
Beispiel #2
0
        public override void Draw(Scene scene)
        {
            int   x         = (int)Position.X - Width / 2;
            int   y         = (int)Position.Y - Height / 2;
            float openCoeff = Math.Min(Ticks / 7f, 1f);

            UI.Draw(FontRenderer, x, y, openCoeff);
            if (openCoeff >= 1)
            {
                scene.SpriteBatch.Draw(RenderTarget, new Rectangle(x, y, RenderTarget.Width, RenderTarget.Height), RenderTarget.Bounds, Color.White);
                //scene.DrawText(Text(), new Vector2(x+8, y+4), Alignment.Left, new TextParameters().SetColor(Color.White,Color.Black).SetConstraints(Width - 16 - 16, Height-8));
            }
        }