- 博客(0)
- 资源 (5)
- 收藏
- 关注
扫雷源码 + 素材 (注释完全)
扫雷源码 + 素材 for (int x = 0; x < widthx; x++) {
for (int y = 0; y < highty; y++) {
gridBlank[x][y] = new Blank();
// grid[x][y].addMouseListener();
}
}
// 开始布雷
count = 40;
do {
for (int x = 0; x < widthx; x++) {
for (int y = 0; y 0) {
if (!(gridBlank[x][y] instanceof Bomb)) {
rdm = new Random().nextInt(widthx * highty / 40);
if (rdm == 1) {
gridBlank[x][y] = new Bomb();
count--;
}
} else {
continue;
}
} else {
break;
}
}
}
} while (count > 0);
2012-01-28
俄罗斯方块源代码+素材+音乐
俄罗斯方块源代码+素材+音乐
一应具全
ublic class BaseShape extends Block {
int col = 5;
int row;
public ArrayList blocks;
public static final int ROTATE = 0;
public static final int LEFT = 1;
public static final int RIGHT = 2;
public static final int DOWN = 3;
public BaseShape() {
super();
// TODO Auto-generated constructor stub
}
public BaseShape(int row, int col) {
super();
this.row = row;
this.col = col;
initBlocks(row ,col);
}
public BaseShape(ArrayList blocks) {
this.blocks = blocks;
}
/**
* 向左移动
* */
2012-01-27
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人