-
C语言写的俄罗斯方块程序
其中的主要逻辑有:
(1)由于c的随机性函数不好,所以每次游戏开始根据bios时间设置种子。
(2)得分越高,方块下降速度
C语言写的俄罗斯方块程序
其中的主要逻辑有:
(1)由于c的随机性函数不好,所以每次游戏开始根据bios时间设置种子。
(2)得分越高,方块下降速度越快(每200分为单位)。
(3)每下落一个方块加1分,每消除一行加10分,两行加30分,三行加70分,四行加150分。初试分数为100分。
游戏控制:
up-旋转;空格-下落到底; 左右下方向键-控制方向。P-开始或暂停游戏。 ESC-退出。
特点:
(1)由于tc不支持中文,所以基本都是英文注释。
(2)函数命名尽可能规范的表达其内部处理目的和过程。
(3)代码加上注释仅有577行。(我下载过的两个俄罗斯方块代码一个在1087行,一个在993行,我的比它们代码少)。
(4)除了消除空格时算法比较复杂,其他算法都比较简单易读。
(5)绘图效率和局部代码效率扔有待提高。
(6)FrameTime参数可能依据不同硬件环境进行具体设置,InitGame需要正确的TC路径。
-err
- 2023-05-30 22:10:03下载
- 积分:1
-
数字频率调制又称频移键控(FSK),二进制频移键控记作2FSK。数字频移键控是用载波的频率来传送数字消息,即用所传送的数字消息控制载波的频率。2FSK信号便是符...
数字频率调制又称频移键控(FSK),二进制频移键控记作2FSK。数字频移键控是用载波的频率来传送数字消息,即用所传送的数字消息控制载波的频率。2FSK信号便是符号“1”对应于载频,而符号“0”对应于载频(与不同的另一载频)的已调波形,而且与之间的改变是瞬间完成的。 -Digital frequency modulation called frequency shift keying (FSK), binary frequency shift keying recorded as 2FSK. Digital frequency-shift keying is the carrier frequency to transmit digital information, that is, the number of messages transmitted with the control of the carrier frequency. 2FSK signal is the symbol of "1" corresponds to the carrier frequency, while the symbol "0" corresponds to the carrier frequency (with a different carrier frequency to another) and modulated waveform, but also between the change was instantaneous.
- 2022-08-23 09:17:39下载
- 积分:1
-
这是一个通用性模块测试程序设计杰姆斯
THIS A GENERIC CHARACTER MODULE TEST PROGRAM DESIGN BY JAMES
MCU =>8051-THIS A GENERIC CHARACTER TEST PRO MODULE GRAM DESIGN BY JAMES MCU =
- 2022-08-20 21:20:32下载
- 积分:1
-
check each string of characters in the number of characters plus flow chart docu...
检查一串字符中每个字符出现的次数外加流程图说明文档-check each string of characters in the number of characters plus flow chart documentation
- 2022-04-29 06:18:16下载
- 积分:1
-
JAVA study into primary, textbooks code calculation and the procedure code conve...
JAVA学习初级变成,课本代码 有关程序计算和代码换算-JAVA study into primary, textbooks code calculation and the procedure code conversion
- 2022-07-11 08:16:44下载
- 积分:1
-
An LCD module on the test procedures CA12232G
一款关于 CA12232G 液晶模块的测试程序 -An LCD module on the test procedures CA12232G
- 2022-01-25 23:06:45下载
- 积分:1
-
Ended at 10:00 p.m. on March 15, 2003 before finishing FAQ valuable CSDN finishe...
截止于2003年3月15日22时以前的CSDN有价值的FAQ整理完毕!asm,asm-Ended at 10:00 p.m. on March 15, 2003 before finishing FAQ valuable CSDN finished! asm, asm
- 2022-07-02 02:57:13下载
- 积分:1
-
关于56F8346DSP芯片如果操作内部FLASH写入
关于56F8346DSP芯片如果操作内部FLASH写入-56F8346DSP chip on if the operator into the internal FLASH
- 2022-06-15 07:26:21下载
- 积分:1
-
在该系统下,将所有的系统中的所有的设备都一一列举出来…
在dos下编程,列举出系统中的全部PCI设备,显示出厂商和设备号-Under the dos program to enumerate all the PCI devices in the system, indicating that manufacturers and device number
- 2022-03-20 05:24:46下载
- 积分:1
-
自己编写的红外解码子程序,但CPU资源占用较高,作教学示范用途。...
自己编写的红外解码子程序,但CPU资源占用较高,作教学示范用途。-prepared their infrared decoding routines, but higher occupancy CPU resources for teaching demonstration purposes.
- 2022-02-24 22:33:40下载
- 积分:1