diff options
Diffstat (limited to 'src/types/mod.rs')
-rw-r--r-- | src/types/mod.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/types/mod.rs b/src/types/mod.rs index 31d2ecd29770..d417e873d8ca 100644 --- a/src/types/mod.rs +++ b/src/types/mod.rs @@ -5,10 +5,13 @@ use std::cmp::max; use std::cmp::Ordering; use std::ops; use std::rc::Rc; + pub mod collision; pub mod command; pub mod direction; pub mod entity_map; +pub mod menu; + pub use collision::Collision; pub use direction::Direction; pub use direction::Direction::*; @@ -78,6 +81,14 @@ impl BoundingBox { }) } + pub fn ll_corner(self) -> Position { + self.position + + (Position { + x: 0, + y: self.dimensions.h as i16, + }) + } + /// Returns a bounding box representing the *inside* of this box if it was /// drawn on the screen. pub fn inner(self) -> BoundingBox { |