Ejemplo n.º 1
0
 public void placeMineAt(int x, int y, double depth, Explosive explosive)
 {
     if (x < Settings.MAP_SIZE && x >= 0 && y < Settings.MAP_SIZE && y >= 0)
     {
         this.fieldArray[x, y].placeExplosive(explosive, depth);
     }
 }
Ejemplo n.º 2
0
 public void placeExplosive(Explosive explosive, double depth)
 {
     this.explosive = explosive;
     if (depth < 0.0)
     {
         this.mineDepth = 0.0;
     }
     else if (depth > MAX_DEPTH)
     {
         this.mineDepth = MAX_DEPTH;
     }
     else
     {
         this.mineDepth = depth;
     }
 }