⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 on.c

📁 嵌入式系统基础课件
💻 C
字号:
#include "libepc.h"
#include "tetris.h"

/* ------------------------------------------------------------ */
/* Each tetris object is a 2x4 (rows x cols) array that can be	*/
/* rotated 0, 90, 180, or 270 degrees.  This function returns	*/
/* TRUE if the specified cell of the array is filled or empty.	*/ 
/* ------------------------------------------------------------ */
BOOL On(int rot, int row, int col)
	{
	static char on[4][2][2] =
		{
		{{1,0},{1,1}},
		{{1,1},{1,0}},
		{{1,1},{0,1}},
		{{0,1},{1,1}}
		} ;

	return on[rot][row][col/2] ;
	}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -