1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
use initiative_macros::WordList;
use serde::{Deserialize, Serialize};

#[derive(Clone, Copy, Debug, Deserialize, Eq, PartialEq, Serialize, WordList)]
#[serde(into = "&'static str", try_from = "&str")]
pub enum GeographyType {
    Archipelago,
    Barrens,
    Coastline,
    Continent,
    Desert,
    Forest,
    Jungle,
    Lake,
    Marsh,
    Mesa,
    Moor,
    Mountain,
    Ocean,
    Plain,
    Plateau,
    Reef,
    Sea,
    Swamp,
    Tundra,
    Wasteland,
    World,
}

impl GeographyType {
    pub const fn get_emoji(&self) -> Option<&'static str> {
        match self {
            Self::Archipelago => Some("🏝"),
            Self::Barrens | Self::Desert | Self::Wasteland => Some("🏜"),
            Self::Coastline | Self::Lake | Self::Sea | Self::Ocean => Some("🌊"),
            Self::Forest | Self::Jungle => Some("🌳"),
            Self::Mountain => Some("⛰"),
            Self::Tundra => Some("❄"),
            Self::World => Some("🌐"),
            Self::Continent
            | Self::Marsh
            | Self::Mesa
            | Self::Moor
            | Self::Plain
            | Self::Plateau
            | Self::Reef
            | Self::Swamp => None,
        }
    }
}