Exemple #1
0
 public MasuInit GetMasu(int x, int y)
 {
     if (x > 9 || y > 9 || x < 1 || y < 1)
     {
         MasuInit masu = new MasuInit();
         masu.Init(0, 0);
         return(masu);
     }
     return(komas [x + "-" + y]);
 }
Exemple #2
0
    // マスを空に
    public void EmptyMasu(int x, int y)
    {
        if (x > 9 || y > 9 || x < 1 || y < 1)
        {
            return;
        }
        MasuInit masu = new MasuInit();

        masu.Init(x, y);
        komas [x + "-" + y] = masu;
    }
Exemple #3
0
 public void Init()
 {
     for (int x = 1; x <= 9; x++)
     {
         for (int y = 1; y <= 9; y++)
         {
             MasuInit masu = new MasuInit();
             masu.Init(x, y);
             komas [x + "-" + y] = masu;
         }
     }
 }