public override void Draw(SpriteBatch spriteBatch)
        {
            if (DataDisplayed)
            {
                spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend);
                Background.draw(spriteBatch);
                FaceWindow.draw(spriteBatch);
                NameBanner.draw(spriteBatch);
                Name.draw(spriteBatch);
                spriteBatch.End();

                Rectangle faceClip = new Rectangle(
                    (int)Face.loc.X + 8 - (FaceWindow.width / 2),
                    (int)Face.loc.Y - (120 + FACE_CLIP_BOTTOM),
                    FaceWindow.width - 16, 120);
                Face.draw(spriteBatch, Vector2.Zero, faceClip);

                Window.draw(spriteBatch);

                if (FieldBaseButton != null && DataDisplayed)
                {
                    spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend);
                    FieldBaseButton.Draw(spriteBatch);
                    spriteBatch.End();
                }

                base.Draw(spriteBatch);
            }
        }
예제 #2
0
        public override void Draw(SpriteBatch spriteBatch)
        {
            if (DataDisplayed)
            {
                spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend);
                Background.draw(spriteBatch);
                spriteBatch.End();

                Window.draw(spriteBatch);

                spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend);
                VersionNumber.draw(spriteBatch);
                spriteBatch.End();
            }

            base.Draw(spriteBatch);
        }
예제 #3
0
        public override void Draw(SpriteBatch spriteBatch)
        {
            if (DataDisplayed)
            {
                spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend);
                Background.draw(spriteBatch);
                if (Scrollbar != null)
                {
                    Scrollbar.draw(spriteBatch);
                }
                spriteBatch.End();


                RasterizerState scissorState = new RasterizerState {
                    ScissorTestEnable = true
                };
                Rectangle textClip = new Rectangle(
                    (int)BASE_OFFSET.X, (int)BASE_OFFSET.Y,
                    Config.WINDOW_WIDTH - (int)(BASE_OFFSET.X * 2),
                    Config.WINDOW_HEIGHT - (int)(BASE_OFFSET.Y * 2));
                spriteBatch.GraphicsDevice.ScissorRectangle =
                    Scene_Map.fix_rect_to_screen(textClip);

                spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend, SamplerState.PointClamp, null, scissorState);
                foreach (var text in CreditsText)
                {
                    text.draw(spriteBatch, ScrollOffset - BASE_OFFSET);
                }
                spriteBatch.End();

                if (FullCreditsButton != null)
                {
                    spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend);
                    FullCreditsButton.Draw(spriteBatch);
                    spriteBatch.End();
                }
            }

            base.Draw(spriteBatch);
        }
예제 #4
0
        public override void Draw(SpriteBatch spriteBatch)
        {
            if (DataDisplayed)
            {
                spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend);
                Background.draw(spriteBatch);
                FaceWindow.draw(spriteBatch);
                spriteBatch.End();

                Rectangle faceClip = new Rectangle(
                    (int)AuguryFace.loc.X + 8 - (FaceWindow.width / 2),
                    (int)AuguryFace.loc.Y - (96 + FACE_CLIP_BOTTOM),
                    FaceWindow.width - 16, 96);
                AuguryFace.draw(spriteBatch, Vector2.Zero, faceClip);

                TextBox.draw(spriteBatch);

                Window.draw(spriteBatch);
            }

            base.Draw(spriteBatch);
        }