summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorYohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer>2011-03-29 01:58:35 +0200
committerYohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer>2011-03-29 01:58:35 +0200
commit0b1ea91fcc77961913af35b89751171327656fb1 (patch)
treec1b1afceecccb00e5f0291dfa68def05fedd825f /src
parentf90aa61947641f3db809e047f80fc7b8c865cb94 (diff)
downloadmana-0b1ea91fcc77961913af35b89751171327656fb1.tar.gz
mana-0b1ea91fcc77961913af35b89751171327656fb1.tar.bz2
mana-0b1ea91fcc77961913af35b89751171327656fb1.tar.xz
mana-0b1ea91fcc77961913af35b89751171327656fb1.zip
Made the Map::findPath() private as it should be used internally.
I also precised the find/Pixel/Tile/Path() documentation.
Diffstat (limited to 'src')
-rw-r--r--src/map.h17
1 files changed, 8 insertions, 9 deletions
diff --git a/src/map.h b/src/map.h
index e807e2ae..a2bd791a 100644
--- a/src/map.h
+++ b/src/map.h
@@ -294,27 +294,21 @@ class Map : public Properties
{ return checkNodeOffsets(radius, walkMask, Position(x, y)); }
/**
- * Find a pixel path from one location to the next.
- * Path node are centered on their corresponding tiles in that case.
+ * Find a tile-centered path in pixel coordinates
+ * from one location to the next.
*/
Path findTilePath(int startPixelX, int startPixelY, int endPixelX,
int endPixelY, unsigned char walkMask,
int maxCost = 20);
/**
- * Find a pixel path from one location to the next.
+ * Find a pixel path from one location to the next using free offsets.
*/
Path findPixelPath(int startPixelX, int startPixelY,
int destPixelX, int destPixelY,
int radius, unsigned char walkmask, int maxCost = 20);
/**
- * Find a path from one location to the next.
- */
- Path findPath(int startX, int startY, int destX, int destY,
- unsigned char walkmask, int maxCost = 20);
-
- /**
* Adds a particle effect
*/
void addParticleEffect(const std::string &effectFile, int x, int y, int w = 0, int h = 0);
@@ -353,6 +347,11 @@ class Map : public Properties
void removeActor(Actors::iterator iterator);
private:
+ /**
+ * Find a path from one location to the next in tile coordinates.
+ */
+ Path findPath(int startX, int startY, int destX, int destY,
+ unsigned char walkmask, int maxCost = 20);
enum LayerType
{