Adding flags

This commit is contained in:
2023-06-07 22:22:13 +01:00
parent f8fa25a2fb
commit 5e0ed2feb8
3 changed files with 87 additions and 8 deletions

View File

@@ -55,4 +55,14 @@ impl Difficulty {
];
DIFFICULTIES.iter()
}
pub fn flag_number(&self) -> &str {
match self {
Difficulty::None => "0",
Difficulty::Baby => "1",
Difficulty::Easy => "2",
Difficulty::Medium => "3",
Difficulty::Hard => "4",
Difficulty::Nightmare => "5",
}
}
}