-
SRAM memory control program is very complete, worthy of serious study, is to hel...
sram 存储器控制程序很完整,值得认真研究,很有帮组-SRAM memory control program is very complete, worthy of serious study, is to help groups
- 2022-05-12 12:55:14下载
- 积分:1
-
迷宫追寻小游戏 C++MFC
应用背景
这个游戏为玩家控制红色方块,去吃掉棕色,绿色,蓝色的方块,一旦一个方块被吃,便会自动生成另一个相同颜色的方块。直到游戏时间结束为止。
程序函数功能:
ondraw函数:
显示游戏界面(用画刷刷成白色),显示地图(黑色),显示食物0,1,2(分别为:棕色,绿色,蓝色),显示玩家(红色)
显示文字,时间,分数。
OnEraseBkgnd函数:
用来更新窗口背景,游戏以位图为窗口背景。
OnGameStart函数:
关联窗口菜单中的开始游戏。包括:
IniGame();(初始化游戏)
m_nGameStatus=1;(游戏状态1,开始)
SetTimer(1,100,NULL);(定时器0.1秒执行一次OnTime)
Invalidate();(转向OnDraw)
IniGame函数:
初始化游戏,确定游戏显示位置,确定玩家初始位置,转向IniAim函数
IniAim函数:
初始化目标,这里的三个目标的位置为随机产生。
OnKeyDown函数:
监控设备按下的键,确定玩家移动方向。
ReDisPlay函数:
重画点所在的小方块。减少对Invalidate()的调用,使屏幕不太闪硕。
OmTimer函数:
完成时间的计算。
关键技术游戏中的人工智能:
棕色方块的移动算法为基本寻路算法—物体沿着墙走。
绿色方块的移动算法为基本的逃避算法—物体总会向玩家的反方向移动。
蓝色方块的移动算法为漫游算法—随机产生一个方向值,物体移动的方向不
- 2022-03-23 18:25:51下载
- 积分:1
-
这是我用vb写的Oicq密码清除补救程序,非常的好用,也非常的实用,请大家多包含...
这是我用vb写的Oicq密码清除补救程序,非常的好用,也非常的实用,请大家多包含-This is what I used to write the worm vb code removal remedy, very convenient, very practical, please include more
- 2022-02-06 09:22:29下载
- 积分:1
-
基于鼠标指针的矢量控制面板程序,并可以显示出…
基于vc的鼠标指针向量控制面板程序,并能显示当前方位-Based on the mouse pointer vc vector control panel procedure, and can display the current position
- 2023-03-19 20:35:04下载
- 积分:1
-
VB的仿制winamp的mp3控件
VB的仿制winamp的mp3控件-VB imitation Winamp MP3 Controls
- 2022-03-15 20:55:59下载
- 积分:1
-
收藏的一部分有关WinCE开发经验,供出来,希望大家一起前进
收藏的一部分有关WinCE开发经验,供出来,希望大家一起前进-part of the collections of WinCE development experience, for, and I hope all of us can! !
- 2022-02-26 00:29:16下载
- 积分:1
-
Primary school curriculum design phase of operation, a c++ poker game, windows,...
小学期的课程设计作业,一个扑克牌c++游戏,windows下 visual c++6.0调试通过 -Primary school curriculum design phase of operation, a c++ poker game, windows, under visual c++6.0 to debug through the
- 2022-01-22 08:09:12下载
- 积分:1
-
Jigsaw puzzle source code
拼图游戏源码-标准的算法,对学习者很有用的-Jigsaw puzzle source code-standard algorithm
- 2022-02-13 04:03:41下载
- 积分:1
-
Enumerate the child windows in accordance with the process name, process ID, the...
枚举子窗口
可根据进程名,进程ID,窗口名称来查找某窗口的所有子窗口,也可根据子窗口的名称查出该子窗口-Enumerate the child windows in accordance with the process name, process ID, the window name to find all the child windows of a window can also be found under the name of the child windows of the child window
- 2022-12-06 13:20:02下载
- 积分:1
-
这是一个能够正常运行的vc编的计算器小程序,希望大家喜欢!我会继续努力的!...
这是一个能够正常运行的vc编的计算器小程序,希望大家喜欢!我会继续努力的!-This is a normal operation of the calculator vc series of small procedures, hope you like them! I will continue to work hard!
- 2022-03-06 13:51:58下载
- 积分:1