VB扫雷游戏的设计与开发.doc
学位论文扫雷游戏的设计与开发论文作者姓名:申请学位专业:网络工程申请学位类别:工学学士指导教师姓名(职称):论文提交日期:扫雷游戏的设计与开发摘要本论文研究的是以VisualBasic6.0为开发环境,设计并开发一款扫雷游戏,其功能类似于Windows操作系统自带的扫雷游戏。论文首先介绍了制作游戏的整体思路及整个游戏设计的流程规划,然后介绍了雷区的布置及地雷随机产生的实现方法;重点介绍了在游戏过程中各事件的处理,其中又以鼠标事件和清除未靠近地雷区方块这两方面最为最要,鼠标事件是利用鼠标所发出的信息了解使用者的意图,进而做出相对应的动作,而清除未靠近地雷区方块由于引进了“递归”这个概念而使其简单化。本次设计只是完成了扫雷游戏的基本功能,在细节方面仍有待以后完善。关键词:扫雷;VisualBasic6.0;事件;递归ThedesignanddevelopmentofmineclearancegameAbstractWhatmythesisresearchforisbasiconthedevelopenvironmentofVisualBasic6.0,designanddevelopamineclearancegame,itsfunctionissimilartothemineclearancegamesoftheWindowsOperatingSystem.Thethesishasintroducedthelayoutofminedareasandthemethodofhowtocreatetheminesatrandom.ItsmainlythroughtheuseofvairiesofcomponentsinVisualBasic6.0andthecombinationofsomesimplecalculations;thethesislaysemphasisonintroducingtheprocessingofeacheventinthegame.Amongtheseevents,themouseeventandtheeventofclearanceoftheareawhichisntclosetotheminefieldaremuchmoreimportant.Thetheoryofmouseeventisthattheintentionofuserislearnedbytheinformationsentoutbythemouseandthentheprogramrunsaccordingtotheinformation.Theothereventissimplifiedbytheintroductionoftheconceptofrecursion.Thisdesignjustcompletedthebasicfunctionofmineclearancegame.Thedetailsstillneedtobeperfect.Keywords:Mineclearance,VisualBasic6.0,Affairs,Recursion目录论文总页数:18页1引言.11.1课题背景及意义.11.2开发工具的选用及介绍.12游戏的总体分析与设计.32.1设计构想.32.2流程规划.42.3画面规划.53游戏的详细设计.63.1游戏初始化.63.2雷区的布置.93.3游戏中主要模块的介绍与使用.103.3.1鼠标事件.103.3.2地雷及雷区表面探测情况.123.3.3清除未靠近地雷的方块.123.3.4游戏难度的选择.143.4游戏的判断.143.4.1游戏成功完成.143.4.2游戏失败.144游戏测试结果.15结论.15参考文献.16致谢.17声明.18