15 static constexpr float kUnreachable = std::numeric_limits<float>::infinity();
31 void setNext(
int x,
int y,
int nx,
int ny);
36 bool inBounds(
int x,
int y)
const;
37 int index(
int x,
int y)
const {
return y * width_ +
x; }
43 std::vector<float> cost_;
44 std::vector<int> nextX_;
45 std::vector<int> nextY_;
std::vector< float > cost
Integration + direction field for group pathfinding to a single goal. nextX/nextY point to the neighb...
bool isReachable(int x, int y) const
void resize(int width, int height)
void setGoal(int x, int y)
float costAt(int x, int y) const
void setNext(int x, int y, int nx, int ny)
static constexpr float kUnreachable
int nextY(int x, int y) const
int nextX(int x, int y) const
void setCost(int x, int y, float cost)
放置世界:格子占用(多通道)+ 地形语义 + 已放置建筑实例。 行为由 PlacementSystem 提供;本类暴露便于脚本绑定的薄封装方法。 坐标换算统一走 eve::grid(支持 rectang...