pub mod renderer;
pub static CLS: &'static str = "\x1B[2J";
pub static CLEAR_CURRENT_LINE: &'static str = "\x1B[2K";
pub static MOVE_BACK_ONE_LINE: &'static str = "\x1B[F";
pub static SAVE_CURSOR_POSITION: &'static str = "\x1B[s";
pub static RESTORE_CURSOR_POSITION: &'static str = "\x1B[u";
pub static RESET_COLOR: &'static str = "\x1B[0m";
pub const COL_INIT: usize = 3;
pub const COL_OFFSET: usize = 3;
pub const LINE_INIT: usize = 2;
pub const LINE_OFFSET: usize = 1;
pub const MAZE_ANIMATION_SPEED: u64 = 2; pub const PATH_ANIMATION_SPEED: u64 = 150;
pub static NORTH_SPRITE: &'static str = "+---+";
pub static EAST_SPRITE: &'static str = "|";
pub static SOUTH_SPRITE: &'static str = "+---+";
pub static WEST_SPRITE: &'static str = "|";
static RED_FONT: &'static str = "\x1B[31m";
static GREEN_FONT: &'static str = "\x1B[32m";
static BLUE_FONT: &'static str = "\x1B[34m";
#[derive(Debug)]
pub enum Color {
RED,
GREEN,
BLUE,
}
impl Color {
fn as_str(&self) -> &'static str {
match *self {
Color::RED => RED_FONT,
Color::GREEN => GREEN_FONT,
Color::BLUE => BLUE_FONT,
}
}
}