![]() |
CMGDK r49-rc2
|
寻路模块基类 更多...
#include <FindPath.H>
组合类型 | |
struct | StepCoord |
class | StepList |
公有成员 | |
DefEvent (bool, CheckPoint,(int, int, int, int)) | |
检查一个点是否可走事件 | |
FindPath (int w, int h) | |
virtual | ~FindPath () |
void | SetStart (int x, int y) |
设置起始点 | |
void | SetEnd (int x, int y) |
设置目标点 | |
bool | Find () |
开始查找 | |
bool | Find (int l, int t, int sx, int sy, int ex, int ey) |
开始查找 | |
bool | Find (int sx, int sy, int ex, int ey) |
开始查找 | |
公有属性 | |
StepList | Steps |
查找的步子结果 | |
int | MaxFind |
最大查找节点数,默认128 | |
保护成员 | |
virtual bool | find_path ()=0 |
保护属性 | |
int | Left |
int | Top |
int | StartX |
int | StartY |
int | EndX |
int | EndY |
int | Width |
int | Height |
寻路模块基类
寻路模块基类描述
virtual hgl::FindPath::~FindPath | ( | ) | [inline, virtual] |
开始查找
开始查找路线
sx | 起始点X坐标 |
sy | 起始点Y坐标 |
ex | 目标点X坐标 |
ey | 目标点Y坐标 |
bool hgl::FindPath::Find | ( | ) |
开始查找
开始查找
开始查找路线
(sx,sy)、(ex,ey)会被减去(l,t)
主要用于超大地图,但只在一部分范围内寻路的处理
l | 左边界 |
t | 上边界 |
sx | 起始点X坐标 |
sy | 起始点Y坐标 |
ex | 目标点X坐标 |
ey | 目标点Y坐标 |
virtual bool hgl::FindPath::find_path | ( | ) | [protected, pure virtual] |
int hgl::FindPath::EndX [protected] |
int hgl::FindPath::EndY [protected] |
int hgl::FindPath::Height [protected] |
int hgl::FindPath::Left [protected] |
最大查找节点数,默认128
int hgl::FindPath::StartX [protected] |
int hgl::FindPath::StartY [protected] |
查找的步子结果
int hgl::FindPath::Top [protected] |
int hgl::FindPath::Width [protected] |