diff options
Diffstat (limited to 'src/entity.rs')
-rw-r--r-- | src/entity.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/entity.rs b/src/entity.rs new file mode 100644 index 0000000..25f30b2 --- /dev/null +++ b/src/entity.rs @@ -0,0 +1,11 @@ +pub use self::player::Player; + +mod player; + +pub(crate) trait Entity { + fn render_map(&self) -> std::collections::HashMap<crate::physics::Point, char>; +} + +pub(crate) trait Controllable { + fn handle_input(&mut self, key: termion::event::Key) -> Option<crate::game::Command>; +} |