diff options
author | rubidium <rubidium@openttd.org> | 2011-01-18 21:58:22 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2011-01-18 21:58:22 +0000 |
commit | d89095b3ecb9c326e169db33294efac9b818276a (patch) | |
tree | bc0ddca8ec8e962661a163d261e655f9acb69bfa /src/tilearea.cpp | |
parent | b8c9988d9fce02a3bfb958b0ebc7cf39961ef10c (diff) | |
download | openttd-d89095b3ecb9c326e169db33294efac9b818276a.tar.xz |
(svn r21843) -Codechange: move documentation towards the code to make it more likely to be updates [t-z].
Diffstat (limited to 'src/tilearea.cpp')
-rw-r--r-- | src/tilearea.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/tilearea.cpp b/src/tilearea.cpp index 498714ec0..7a5bf9f44 100644 --- a/src/tilearea.cpp +++ b/src/tilearea.cpp @@ -104,6 +104,11 @@ void TileArea::ClampToMap() this->h = min(this->h, MapSizeY() - TileY(this->tile)); } +/** + * Construct the iterator. + * @param begin Tile from where to begin iterating. + * @param end Tile where to end the iterating. + */ DiagonalTileIterator::DiagonalTileIterator(TileIndex corner1, TileIndex corner2) : TileIterator(corner2), base_x(TileX(corner2)), base_y(TileY(corner2)), a_cur(0), b_cur(0) { assert(corner1 < MapSize()); @@ -135,6 +140,9 @@ DiagonalTileIterator::DiagonalTileIterator(TileIndex corner1, TileIndex corner2) } } +/** + * Move ourselves to the next tile in the rectange on the map. + */ TileIterator &DiagonalTileIterator::operator++() { assert(this->tile != INVALID_TILE); |