You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
59 lines
1.1 KiB
59 lines
1.1 KiB
pub mod area;
|
|
pub mod enemy;
|
|
pub mod object;
|
|
pub mod variant;
|
|
pub mod maps;
|
|
pub mod monster;
|
|
pub mod room;
|
|
|
|
#[derive(Clone, Copy)]
|
|
pub enum Holiday {
|
|
None,
|
|
Christmas,
|
|
Valentines,
|
|
Easter,
|
|
Halloween,
|
|
Sonic,
|
|
NewYear,
|
|
Summer,
|
|
White,
|
|
Wedding,
|
|
Fall,
|
|
Spring,
|
|
Summer2,
|
|
Spring2,
|
|
}
|
|
|
|
|
|
impl From<Holiday> for u32 {
|
|
fn from(other: Holiday) -> u32 {
|
|
u16::from(other) as u32
|
|
}
|
|
}
|
|
|
|
impl From<Holiday> for u16 {
|
|
fn from(other: Holiday) -> u16 {
|
|
u8::from(other) as u16
|
|
}
|
|
}
|
|
|
|
impl From<Holiday> for u8 {
|
|
fn from(other: Holiday) -> u8 {
|
|
match other {
|
|
Holiday::None => 0,
|
|
Holiday::Christmas => 1,
|
|
Holiday::Valentines => 3,
|
|
Holiday::Easter => 4,
|
|
Holiday::Halloween => 5,
|
|
Holiday::Sonic => 6,
|
|
Holiday::NewYear => 7,
|
|
Holiday::Summer => 8,
|
|
Holiday::White => 9,
|
|
Holiday::Wedding => 10,
|
|
Holiday::Fall => 11,
|
|
Holiday::Spring => 12,
|
|
Holiday::Summer2 => 13,
|
|
Holiday::Spring2 => 14,
|
|
}
|
|
}
|
|
}
|