findpath.h

来自「最经典的A星寻路算法,自己写的,感觉很好!」· C头文件 代码 · 共 27 行

H
27
字号
struct Node
{
	POINT	pos;
	struct	Node	*father;
	int		value;
	struct	Node	*next;
};

class List
{
public:
	Node	*head;
	void	Insert(POINT pp, Node *fnode, int assess = 0);
	void	Insert(Node	*node);
	void	Delete(POINT pp);
	Node	*GetTop(POINT *pp);
	bool	Empty();
	bool	Exsit(POINT pp);
	BOOL	GetParent(POINT *sonpos);

public:
	List();
	~List();
};

int		GetAssess(POINT	temppos, POINT startpos, POINT endpos);
bool	Findpath(POINT start, POINT end);

⌨️ 快捷键说明

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