在此图层第6 帧添加as: stopDrag(); //停止拖动挡板 c = 0; r = 0; //c和r为两个循环变量 while (Number(r)<18) { while (Number(c)<10) { removeMovieClip("brick" add r add c); c = Number(c)+1; } r = Number(r)+1; c = 0; } //初始化变量,对游戏进行数值统计
在此图层第7 帧添加as: stop();
在此图层第10 帧添加as: xspeed = 0; border = 240; bricknumber = 50; Level_index = Number(Level_index)+1; //设置游戏的等级 c = 0; r = 0; //c和r为两个循环变量 count = 1; index = 0; while (Number(r)<5) { while (Number(c)<Number(10-index)) { duplicateMovieClip("/brickred", "brick" add r add c, Number(count)+1); setProperty("brick" add r add c, _x, 220+Number(40*c)); setProperty("brick" add r add c, _y, 50+Number(20*r)); c = Number(c)+1; count = Number(count)+1; } //复制对象brickred r = Number(r)+2; index = Number(index)+2; c = index; } c = 1; r = 1; //c和r为两个循环变量 index = 0; while (Number(r)<5) { while (Number(c) duplicateMovieClip("/brickblue", "brick" add r add c, Number(count)+1); setProperty("brick" add r add c, _x, 220+Number(40*c)); setProperty("brick" add r add c, _y, 50+Number(20*r)); c = Number(c)+1; count = Number(count)+1; } //复制对象brickblue r = Number(r)+2; index = Number(index)+2; c = Number(index)+1; } c = 0; r = 7; //c和r为两个循环变量 while (Number(r)<9) { while (Number(c)<10) { duplicateMovieClip("/brickgreen", "brick" add r add c, Number(count)+1); //复制对象brickgreen,一共复制16个 setProperty("brick" add r add c, _x, 220+Number(40*c)); setProperty("brick" add r add c, _y, 50+Number(20*r)); c = Number(c)+1; count = Number(count)+1; } //设置复制出的砖块的坐标 c = 0; r = Number(r)+1; } setProperty("/brick", _visible, false); 在此图层第11 帧添加as,下面的as和第10帧相类似,不过游戏的等级更高 xspeed = 1; border = 150; bricknumber = 50; Level_index = Number(Level_index)+1; c = 0; r = 0; //c和r为两个循环变量 count = 1; while (Number(r)<5) { while (Number(c)<10) { if (((Number(r)<=Number(c)) and (Number(c)<5)) or ((Number(c)>=5) and (Number(c)<=Number(9-r)))) { duplicateMovieClip("/brick", "brick" add r add c, Number(count)+1); } else { duplicateMovieClip("/brickgreen", "brick" add r add c, Number(count)+1); } setProperty("brick" add r add c, _x, 220+Number(40*c)); setProperty("brick" add r add c, _y, 50+Number(20*r)); count = Number(count)+1; c = Number(c)+1; } //复制对象brick r = Number(r)+1; c = 0; }
在此图层第12 帧添加as, 下面的as和第11帧相类似,不过游戏的等级更高 xspeed = 2; border = 330; bricknumber = 60; c = 0; r = 0; //c和r为两个循环变量 count = 1; while (Number(r)<14) { while (Number(c)<10) { if ((Number(r) == 5) or (Number(r) == 8)) { duplicateMovieClip("/brickred", "brick" add r add c, Number(count)+1); } else if ((Number(r) == 13) or (Number(r) == 0)) { duplicateMovieClip("/brickblue", "brick" add r add c, Number(count)+1); } else if ((Number(r) == 7) or (Number(r) == 6)) { duplicateMovieClip("/brick", "brick" add r add c, Number(count)+1); } setProperty("brick" add r add c, _x, 220+Number(40*c)); setProperty("brick" add r add c, _y, 50+Number(20*r)); c = Number(c)+1; count = Number(count)+1; } r = Number(r)+1; c = 0; } setProperty("/brick", _visible, false);
在此图层第13 帧添加as,下面的as和第12帧相类似,不过游戏的等级更高 xspeed = 3; border = 250; bricknumber = 72; c = 0; r = 0; //c和r为两个循环变量 count = 1; while (Number(r)<10) { while (Number(c)<10) { if (((Number(r)>1) and (Number(r)<8) and (Number(c)>3) and (Number(c)<6)) or ((Number(c)>1) and (Number(c)<8) and (Number(r)>3) and (Number(r)<6))) { duplicateMovieClip("/brickgreen", "brick" add r add c, Number(count)+1); } else if (((Number(r) == Number(Number(5-9)+Number(c))) and (Number(r)>0) and (Number(r)<5)and (Number(c)>4) and (Number(c)<9)) or ((Number(r) == Number(5-c)) and (Number(r)>0) and (Number(r)<5) and (Number(c)>0) and (Number(c)<5)) or ((Number(9-r) == Number(5-c)) and (Number(r)>4) and (Number(r)<9) and (Number(c)>0) and (Number(c)<5)) or ((Number(9-r) == Number(Number(5-9)+Number(c))) and (Number(r)>4) and (Number(r)<9) and (Number(c)>4) and (Number(c)<9))) { duplicateMovieClip("/brickred", "brick" add r add c, Number(count)+1); } else if ((Number(r)>8) or (Number(r) == 0) or (Number(c) == 0) or (Number(c) == 9)) { duplicateMovieClip("/brickblue", "brick" add r add c, Number(count)+1); } setProperty("brick" add r add c, _x, 220+Number(40*c)); setProperty("brick" add r add c, _y, 50+Number(20*r)); c = Number(c)+1; count = Number(count)+1; } r = Number(r)+1; c = 0; } setProperty("/brick", _visible, false);
在此图层第14 帧添加as,下面的as和第13帧相类似,不过游戏的等级更高 border = 370; bricknumber = 116; c = 0; r = 0; //c和r为两个循环变量 count = 1; while (Number(r)<16) { while (Number(c)<10) { if (((Number(r)>1) and (Number(r)<9) and (Number(c) == 3)) or ((Number(r)>1) and (Number(r)<9)and (Number(c) == 6))) { duplicateMovieClip("/brickblue", "brick" add r add c, Number(count)+1); } else if (((Number(r)>1) and (Number(r)<9) and (Number(c) == 1)) or ((Number(r)>1) and (Number(r)<9) and (Number(c) == 8))) { duplicateMovieClip("/brickred", "brick" add r add c, Number(count)+1); } else if (((Number(r) == 0) and (Number(c)>2) and (Number(c)<7)) or ((Number(r) == 7) and (Number(c)>2) and (Number(c)<7)) or ((Number(r) == 8) and (Number(c)>2) and (Number(c)<7))) { duplicateMovieClip("/brickblue", "brick" add r add c, Number(count)+1); } else if ((Number(r) == 1)) { duplicateMovieClip("/brickgreen", "brick" add r add c, Number(count)+1); } else if (Number(r)>8) { duplicateMovieClip("/brick", "brick" add r add c, Number(count)+1); } setProperty("brick" add r add c, _x, 220+Number(40*c)); setProperty("brick" add r add c, _y, 50+Number(20*r)); c = Number(c)+1; count = Number(count)+1; } r = Number(r)+1; c = 0; v} setProperty("/brick", _visible, false);