* Clamp the tile area to map borders. */
| 140 | * Clamp the tile area to map borders. |
| 141 | */ |
| 142 | void OrthogonalTileArea::ClampToMap() |
| 143 | { |
| 144 | assert(this->tile < Map::Size()); |
| 145 | this->w = std::min<int>(this->w, Map::SizeX() - TileX(this->tile)); |
| 146 | this->h = std::min<int>(this->h, Map::SizeY() - TileY(this->tile)); |
| 147 | } |
| 148 | |
| 149 | /** |
| 150 | * Returns an iterator to the beginning of the tile area. |
no test coverage detected