diff options
author | Luis Ferro <luis.ferro@eggplant.io> | 2019-11-12 14:28:32 +0100 |
---|---|---|
committer | Luis Ferro <luis.ferro@eggplant.io> | 2019-11-12 14:28:32 +0100 |
commit | 857d7a8eccec2493163dbb1ae2f45a24a52f108c (patch) | |
tree | 5c6837e528b56d9f00dc637fdf1edb962e1b0987 /src/main.rs | |
parent | e7b227ed268e8570518f9d1452b5e7d0d0a0ee32 (diff) | |
parent | 8fa3fa881bc3b954e136295fe6cc7022737ae9db (diff) |
Fix conflicts
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 24 |
1 files changed, 5 insertions, 19 deletions
diff --git a/src/main.rs b/src/main.rs index 08e1b25..9f5e45b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -4,16 +4,14 @@ extern crate pancurses; #[macro_use] extern crate text_io; -mod character; -mod computer; +mod entities; mod world; +mod tiling; -use std::env; -use character::Player; -use character::Character; -use computer::Enemy; +use entities::{Character, Player, Entity}; use pancurses::{Window, initscr, endwin, Input, noecho}; -use world::{Dungeon, Level, Generable, TileType}; +use world::{Dungeon, Level, Generatable}; +use tiling::TileType; fn tile_to_str(tile: &TileType) -> &str { match tile { @@ -42,18 +40,6 @@ fn render_level(window: &Window, level: &Level) { } } -fn debug_level(level: Level) { - let grid = level.to_tilegrid().unwrap(); - - for line in grid.raw_data().iter() { - for block in line.iter() { - print!("{}", tile_to_str(block)); - } - print!("\n"); - } -} - - fn main() { let window = initscr(); let mut level = 0; |