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

📄 basemethod.h

📁 两个人工智能小程序
💻 H
字号:
#if !defined(AFX_BASEMETHOD_H__6A606901_2986_11D9_8F87_A1FB26067535__INCLUDED_)
#define AFX_BASEMETHOD_H__6A606901_2986_11D9_8F87_A1FB26067535__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// BaseMethod.h : header file
//
#include <afxtempl.h>
/////////////////////////////////////////////////////////////////////////////
// CBaseMethod window
struct OPEN{
		BYTE matrix[3][3];//存放状态结构
		int returnPoint;//返回指针
		int gValue;
		int hValue;
	};
	struct CLOSED{
		int SelfNumber;
		BYTE matrix[3][3];
		int returnPoint;
		int gValue;
		int hValue;
	};
class CBaseMethod : public CView
{
// Construction
public:
	CBaseMethod();

// Attributes
public:
	BYTE basematrix[3][3];
	BYTE destmatrix[3][3];
	BYTE m_xIndex;
	BYTE m_yIndex;
	void OnDraw(CDC* pDC);
	BOOL IsSuccess;

	CList <OPEN,OPEN> *OpenList;
	CList <CLOSED,CLOSED> *ClosedList;

// Operations
public:
	BOOL OnResolve();
// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CBaseMethod)
	//}}AFX_VIRTUAL

// Implementation
public:
	void SetWitchOne(int witch);
	int m_witchone;
	int m_SearchDepth;
	void SetDepth(int m_Depth);
	BOOL CanOutPut;
	void CreateOutputList();
	BOOL IsFinish;
	CPoint m_tableRD;
	CPoint m_tableLU;
	BOOL IsTheSame(BYTE matrix1[][3],BYTE matrix2[][3]);
	BOOL IsInClosedList(OPEN opElem);
	BOOL IsInOpenList(OPEN opElem);
	int CreateHValue(BYTE matrix[][3]);
	BOOL SearchZeroIndex(BYTE matrix[][3]);
	BOOL IsGetGoal(BYTE matrix[][3]);
	OPEN ChooseMinFromOpen();
	virtual ~CBaseMethod();

	// Generated message map functions
protected:
	//{{AFX_MSG(CBaseMethod)
		// NOTE - the ClassWizard will add and remove member functions here.
	//}}AFX_MSG

	DECLARE_MESSAGE_MAP()
};

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_BASEMETHOD_H__6A606901_2986_11D9_8F87_A1FB26067535__INCLUDED_)

⌨️ 快捷键说明

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