コード例 #1
0
ファイル: Game1.cs プロジェクト: chrisdaher/2DBubbleBreaker
 public void changeLevel()
 {
     Components.Remove(main);
       Components.Remove(player);
       CurrentLevel = 2;
       sprite = Content.Load<Texture2D>("Bubbles");
       BubbleCreator.setXNA(this, sprite);
       main = new BoardMain(this, sprite, CurrentLevel);
       arrowSprite = Content.Load<Texture2D>("Arrow");
       player = new BoardPlayer(this, sprite, arrowSprite);
       BubbleHolder.score = 0;
       Components.Add(main);
       Components.Add(player);
 }
コード例 #2
0
 public BoardGame(Game game, int lvl)
     : base(game)
 {
     bubbleBoard = new BoardMain(game, lvl);
     playerBoard = new BoardPlayer(game);
 }
コード例 #3
0
 public BoardGame(Game game, int lvl)
     : base(game)
 {
     bubbleBoard = new BoardMain(game, lvl);
       playerBoard = new BoardPlayer(game);
 }
コード例 #4
0
ファイル: Game1.cs プロジェクト: chrisdaher/2DBubbleBreaker
        protected override void LoadContent()
        {
            spriteBatch = new SpriteBatch(GraphicsDevice);
              Services.AddService(typeof(SpriteBatch),spriteBatch);
              sprite = Content.Load<Texture2D>("Bubbles");
              BubbleCreator.setXNA(this, sprite);
              main = new BoardMain(this, sprite, CurrentLevel);
              arrowSprite = Content.Load<Texture2D>("Arrow");
              player = new BoardPlayer(this, sprite, arrowSprite);

              wall = new Texture2D(GraphicsDevice, 1, 1, false, SurfaceFormat.Color);
              wall.SetData(new[] { Color.White });

              Components.Add(main);
              Components.Add(player);
        }