//ɨÀ×ÓÎÏ·
#include <graphics.h>
#include <stdlib.h>
#include <dos.h>
#define LEFTPRESS 0xff01
#define LEFTCLICK 0xff10
#define LEFTDRAG 0xff19
#define MOUSEMOVE 0xff08
struct
{
int num;
int roundnum;
int flag;
}Mine[10][10];
int gameAGAIN=0;
int gamePLAY=0;
int mineNUM;
char randmineNUM[3];
int Keystate;
int MouseExist;
int MouseButton;
int MouseX;
int MouseY;
void Init(void);
void MouseOn(void);
void MouseOff(void);
void MouseSetXY(int,int);
int LeftPress(void);
int RightPress(void);
void MouseGetXY(void);
void Control(void);
void GameBegain(void);
void DrawSmile(void);
void DrawRedflag(int,int);
void DrawEmpty(int,int,int,int);
void GameOver(void);
void GameWin(void);
int MineStatistics(int,int);
int ShowWhite(int,int);
void GamePlay(void);
void Close(void);
void main(void)
{
Init();
Control();
Close();
}
void Init(void)
{
int gd=DETECT,gm;
initgraph(&gd,&gm,"D:\\tc20\\BGI");
}
void Close(void)
{
closegraph();
}
void MouseOn(void)
{
_AX=0x01;
geninterrupt(0x33);