📄 blackwhitechessdlg.h
字号:
// blackwhitechessDlg.h : header file
//
#if !defined(AFX_BLACKWHITECHESSDLG_H__459F7AEE_1602_4503_9EE6_AFCB36016E9E__INCLUDED_)
#define AFX_BLACKWHITECHESSDLG_H__459F7AEE_1602_4503_9EE6_AFCB36016E9E__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
/////////////////////////////////////////////////////////////////////////////
// CBlackwhitechessDlg dialog
typedef struct {
int x;
int y;
} node;
class CBlackwhitechessDlg : public CDialog
{
// Construction
public:
CBlackwhitechessDlg(CWnd* pParent = NULL); // standard constructor
int Result[10][10];
int Last[10][10];
int PositionValue[10][10];
node Point[40];
node BestPoint;
int AvilNum;
int Color;
int MaxDepth;
BOOL Avilhuman,Avilcpu;
void Reverse(int n,int x,int y);
void Reverse(int n,node no);
void NextPoint(int n,node* no);
void CountNum();
void JudgeWinner();
BOOL Available(int x,int y);
BOOL ComputerPlay();
BOOL HumanPlay();
void ShowChess(UINT num,int x,int y);
void ShowChess(UINT num,node no);
int Search(int Cl,int Depth,int Alpha,int Beta);
void ParaInit();
// Dialog Data
//{{AFX_DATA(CBlackwhitechessDlg)
enum { IDD = IDD_BLACKWHITECHESS_DIALOG };
int m_BlockNum;
int m_WhiteNum;
int m_Color;
int m_BlackNum;
int m_WhiteNumber;
//}}AFX_DATA
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CBlackwhitechessDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
HICON m_hIcon;
// Generated message map functions
//{{AFX_MSG(CBlackwhitechessDlg)
virtual BOOL OnInitDialog();
afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
afx_msg void OnPaint();
afx_msg HCURSOR OnQueryDragIcon();
afx_msg void OnButton1();
afx_msg void OnButton2();
afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
afx_msg void OnRadio1();
afx_msg void OnRadio2();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_BLACKWHITECHESSDLG_H__459F7AEE_1602_4503_9EE6_AFCB36016E9E__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -