Flash游戏制作:打砖块
作者 佚名技术
来源 服务器技术
浏览
发布时间 2012-07-14
ber(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); 在此图层第15 帧添加as: endgame = true; Level_index = Number(Level_index)+1; 最后时间线如图18所示: 图18 最后您就可以进行游戏的测试了。本游戏的制作难度属于中等难度,掌握好此游戏的制作方法,您还可以尝试更复杂一些的游戏制作。源文件下载 关键词:游戏 |
凌众科技专业提供服务器租用、服务器托管、企业邮局、虚拟主机等服务,公司网站:http://www.lingzhong.cn 为了给广大客户了解更多的技术信息,本技术文章收集来源于网络,凌众科技尊重文章作者的版权,如果有涉及你的版权有必要删除你的文章,请和我们联系。以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢! |
你可能对下面的文章感兴趣
上一篇: 轻松实现Flash动态背景下一篇: Flash游戏制作挑战:方块游戏
关于Flash游戏制作:打砖块的所有评论