diff options
Diffstat (limited to 'src/tilearea_type.h')
-rw-r--r-- | src/tilearea_type.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/tilearea_type.h b/src/tilearea_type.h index 45bfb3d4c..11094ea17 100644 --- a/src/tilearea_type.h +++ b/src/tilearea_type.h @@ -44,6 +44,16 @@ struct OrthogonalTileArea { this->h = 0; } + inline bool IsEmpty() const + { + return (w==0 && h==0); + } + + inline bool IsFinite() const + { + return (w!=0 && h!=0); + } + bool Intersects(const OrthogonalTileArea &ta) const; bool Contains(TileIndex tile) const; |