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
653 B
C
Raw Normal View History

2012-10-01 07:09:05 +00:00
/*
2012-12-20 14:07:47 +00:00
* pathfinder.h
2012-10-01 07:09:05 +00:00
*
* Created on: 24.09.2012
* Author: Felix
*/
2012-12-20 14:07:47 +00:00
#ifndef PATHFINDER_H_
#define PATHFINDER_H_
2012-10-01 07:09:05 +00:00
#include <Box2D/Box2D.h>
#include "../abstract/Body.h"
2012-10-14 16:14:06 +00:00
#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(Body& physical, const Vector2f& destination);
2012-10-01 07:09:05 +00:00
// 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;
};
2012-12-20 14:07:47 +00:00
#endif /* PATHFINDER_H_ */