This repository has been archived on 2019-12-07. You can view files and clone it, but cannot push or open issues or pull requests.
dungeon-gunner/source/util/Pathfinder.h

36 lines
641 B
C
Raw Normal View History

2012-10-01 07:09:05 +00:00
/*
* astar.h
*
* Created on: 24.09.2012
* Author: Felix
*/
#ifndef ASTAR_H_
#define ASTAR_H_
#include <Box2D/Box2D.h>
2012-10-14 16:14:06 +00:00
#include "../abstract/Physical.h"
#include "../types/Vector.h"
2012-10-01 07:09:05 +00:00
/**
* Interface class for Boost Graph A* library.
*/
class Pathfinder {
// Public functions.
public:
Pathfinder(b2World& world);
std::vector<Vector2f> getPath(Physical& physical, const Vector2f& destination);
// Private variables.
private:
/// The size of a vertex in pixels. Should be between the size of the moving object
/// and TileManager::TILE_SIZE.
static const Vector2f VERTEX_SIZE;
b2World& mWorld;
};
#endif /* ASTAR_H_ */