veloren/common/src/figure/mat_cell.rs

35 lines
557 B
Rust
Raw Normal View History

use crate::vol::Vox;
use vek::*;
#[derive(Copy, Clone, Debug, PartialEq, Eq)]
pub enum Material {
Skin,
2019-09-18 16:46:12 +00:00
SkinDark,
SkinLight,
Hair,
EyeDark,
EyeLight,
EyeWhite,
/*HairLight,
*HairDark,
*Clothing, */
}
#[derive(Copy, Clone, Debug, PartialEq, Eq)]
pub enum MatCell {
None,
Mat(Material),
Normal(Rgb<u8>),
}
impl Vox for MatCell {
fn empty() -> Self { MatCell::None }
fn is_empty(&self) -> bool {
match self {
MatCell::None => true,
_ => false,
}
}
}