#ifndef _clsMaze_H #define _clsMaze_H #include #include using namespace std; #define NL 0x0D0A #define U_BOM 0xFEFF #define U_CR 0x000D #define U_LF 0x000A #define U_LDR 0x250C//+ #define U_LH 0x2500//- #define U_LUH 0x2534//- #define U_LDL 0x2510//+ #define U_LVL 0x2524//¦ #define U_LV 0x2502//¦ #define U_LDH 0x252C//- #define U_LUR 0x2514//+ #define U_LUL 0x2518//+ #define U_Delim 0x0009//; #define A_LDR 'A' //+ #define A_LH 'B'//- #define A_LUH 'C'//- #define A_LDL 'D'//+ #define A_LVL 'C'//¦ #define A_LV 'E'//¦ #define A_LDH 'F'//- #define A_LUR 'G'//+ #define A_LUL 'H'//+ #define A_Delim 0x0009//; class clsMaze { public: int CELL_WIDTH; int CELL_HEIGHT; int offsetWidth; int offsetHeight; int Rows; int Cols; int dSize; const int NW = 4;//1 static const COLORREF WALL_COLOR = RGB(255,0,0); list lstRows; clsMaze(int wC,int HC,int ox, int oy); ~clsMaze(); list lstMap; bool Load(char *sFile); void Draw(HDC hdc); void DrawWall(HDC hdc, int CurrCol, int CurrRow, int iSide, int wp = 2); private: void DrawCell(HDC hdc,int CurrRow, int CurrCol); }; #endif