1#ifndef NANOMMO_TERRAIN_PATHS_H_
2#define NANOMMO_TERRAIN_PATHS_H_
45 int SquareOf(
Place place)
const;
46 Place Middle(
int square)
const;
48 float Estimate(
int square,
int goal)
const;
51 std::vector<Place> Straighten(
Place from,
52 const std::vector<Place>& squares)
const;
56 std::vector<bool> open_;
61 std::vector<float> cost_;
62 std::vector<int> came_from_;
63 std::vector<uint32_t> stamp_;
static constexpr float kSquare
In metres along each side.
bool Clear(Place from, Place to) const
int searched() const
How many squares the last search looked at.
std::vector< Place > Find(Place from, Place to)
bool Open(Place place) const
Whether the square the place is in is one a player can walk on.
static constexpr int kMostSearched
A little under a sixth of the island's squares.
Paths(const Terrain &terrain)
In metres from the middle of a land.