コード例 #1
0
ファイル: Game1.cs プロジェクト: niklasCarstensen/Minesweeper
 public Game1()
 {
     graphics = new GraphicsDeviceManager(this);
     Content.RootDirectory              = "Content";
     MineSweeper                        = new MineSweeperField(new Rectangle(0, 0, ElementSize * 35, ElementSize * 35), ElementSize, 175);
     Values.WindowSize                  = new Vector2(MineSweeper.Field.Width, MineSweeper.Field.Height + MineSweeper.Field.Y);
     graphics.PreferredBackBufferWidth  = (int)Values.WindowSize.X;
     graphics.PreferredBackBufferHeight = (int)Values.WindowSize.Y;
     IsMouseVisible                     = true;
 }
コード例 #2
0
 public MineSweeperElement(int x, int y, int Size, MineSweeperField MotherField)
 {
     HasBomb = false; IsRevealed = false; TouchingBombsCount = 0;
     this.x  = x; this.y = y; this.Size = Size; PointGotAnim = 50000; this.MotherField = MotherField;
 }