-
c++编的ShowAnimation程序
c++编的ShowAnimation程序-ShowAnimation procedures
- 2023-09-02 12:10:03下载
- 积分:1
-
Intusion detection system
Intusion detection system-1
- 2023-01-02 08:45:04下载
- 积分:1
-
DLL has been kidnapped to prevent some of the basic functions, to achieve the ba...
预防DLL被挟持的一些基本功能,实现了基本饿保护,代码简单,可自行修改-DLL has been kidnapped to prevent some of the basic functions, to achieve the basic hungry protection, the code simple, free to modify the
- 2022-03-13 15:18:21下载
- 积分:1
-
用C语言读取SEGY文件数据的小程序
利用C语言编写的读取Segy文件数据的小程序-Using C language to read file data Segy small program
- 2022-05-26 22:41:16下载
- 积分:1
-
汽车救援调度系统
开发此项目,是为了快速解决用户的救援请求,
使后台工作人员分工更加明确,很好的为用户服务
- 2022-08-17 03:50:26下载
- 积分:1
-
另一拼图游戏的源代码
另一拼图游戏的源代码-another source puzzles
- 2022-07-24 17:23:08下载
- 积分:1
-
一个MFC类,提供你的能力来检查无效的字符的字符串…
An MFC Class which offers you the abbility to check Strings for invalid characters 检验字符串是否含有无效字符的类-An MFC Class which offers you the abbility to check for invalid characters Strings test whether a string containing invalid characters in the category
- 2022-04-29 03:48:13下载
- 积分:1
-
VBA合并两个Excel表的数据到目标表
"" 从src1.name和src2.age按ID获取数据,然后将数据设置为dst
Sub hebing()
Dim dstRowNo As Long
Dim src1RowNo As Long
Dim src2RowNo As Long
With ActiveWorkbook
dstRowNo = 1
Do While .Sheets("dst").Cells(dstRowNo, 1).Text ""
dstID = .Sheets("dst").Cells(dstRowNo, 1).Text
src1RowNo = 1
Do While .Sheets("src1").Cells(src1RowNo, 1).Text ""
src1ID = .Sheets("src1").Cells(src1RowNo, 1).Text
If dstID = src1ID Then
- 2022-02-04 08:02:48下载
- 积分:1
-
对应<EVC高级编程及其应用开发>中在wince系统下远程访问sql数据库的一段代码,测试通过完整版(包括关键语句),有些例子的源码少了几句话,实际...
对应中在wince系统下远程访问sql数据库的一段代码,测试通过完整版(包括关键语句),有些例子的源码少了几句话,实际运行并不正常-Corresponding Wince system in sql database remote access code, testing through the full version (including key words), some examples of source code a few words short of the actual operation is not normal
- 2022-06-19 10:14: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