Beispiel #1
0
        public override void Draw(GameTime gameTime)
        {
            GraphicsDevice.Clear(Color.CornflowerBlue);
            AlienGame.GetSpriteBatch().Begin(SpriteSortMode.Deferred, null, SamplerState.PointClamp);

            MenuList.Draw(gameTime, AlienGame.GetSpriteBatch());

            AlienGame.GetSpriteBatch().End();
        }
Beispiel #2
0
        public override void Draw(GameTime gameTime)
        {
            GraphicsDevice.Clear(Color.CornflowerBlue);
            AlienGame.GetSpriteBatch().Begin(SpriteSortMode.Deferred, null, SamplerState.PointClamp);

            Entities.Draw(AlienGame.GetSpriteBatch());
            MenuList.Draw(gameTime, AlienGame.GetSpriteBatch());
            _timerText.Text  = $"TIME: {Math.Truncate(_timer)}";
            _alienCount.Text = $"ALIENS: {Entities.Count}";

            AlienGame.GetSpriteBatch().End();
        }
Beispiel #3
0
 public OptionsMenuScene(AlienGame game)
     : base(game)
 {
 }
Beispiel #4
0
        private void CheckBox_OnEnabled(object sender, System.EventArgs e)
        {
            ConfigManager.SetUseDefaultName(true);

            _checkBox.Position         = new Vector2(_checkBox.Position.X, 100);
            _defaultNameTitle.Position = new Vector2(_defaultNameTitle.Position.X, 95);

            _textBox = new TextBox(new Rectangle((AlienGame.ScreenWidth / 2) - (AlienGame.ScreenWidth / 4), 130, 300, 35), 3, "", AlienGame.GetGraphicsDevice(),
                                   _buttonFont, true, true, false, Slider.DefaultBarColor, new Color(80, 92, 110), Color.White, Color.White, Color.Gray, 3, 10);
            _textBox.Text.String       = ConfigManager.GetDefaultName();
            _textBox.Cursor.TextCursor = _textBox.Text.Length;
            _textBox.EnterDown        += TextBox_OnEnter;
        }
Beispiel #5
0
 public Scene(AlienGame game)
     : base(game)
 {
     Entities = new EntityList(this);
 }
Beispiel #6
0
 public MainMenuScene(AlienGame game)
     : base(game)
 {
 }
Beispiel #7
0
 public CreditsScene(AlienGame game)
     : base(game)
 {
 }
Beispiel #8
0
 public GameScene(AlienGame game)
     : base(game)
 {
 }