From d10e4641043bfec00586535c26622da80269620b Mon Sep 17 00:00:00 2001 From: Nilstrieb <48135649+Nilstrieb@users.noreply.github.com> Date: Mon, 17 Apr 2023 22:08:27 +0200 Subject: [PATCH] more --- src/tiles.rs | 24 ------------------------ tiles.rs | 22 ---------------------- 2 files changed, 46 deletions(-) diff --git a/src/tiles.rs b/src/tiles.rs index 2130ac4..52d5a62 100644 --- a/src/tiles.rs +++ b/src/tiles.rs @@ -25,7 +25,6 @@ pub enum Mid {} #[derive(Debug)] pub enum Fg {} - pub trait TileLayer { /// Definitions specific to this layer type SpecificDef; @@ -43,28 +42,6 @@ impl TileLayer for Fg { type SpecificDef = (); } -pub type BgTileId = TileId; -pub type MidTileId = TileId; -pub type FgTileId = TileId; - -impl BgTileId { - pub const DIRT: Self = Self(1, PhantomData); - pub const STONE: Self = Self(2, PhantomData); -} - -impl MidTileId { - pub const DIRT: Self = Self(1, PhantomData); - pub const STONE: Self = Self(2, PhantomData); - pub const TORCH: Self = Self(3, PhantomData); - pub const PLATFORM: Self = Self(4, PhantomData); - pub const PANZERIUM: Self = Self(5, PhantomData); - pub const UNBREAKANIUM: Self = Self(6, PhantomData); -} - -impl FgTileId { - pub const COAL: Self = Self(1, PhantomData); -} - #[derive(Serialize, Deserialize, Inspect)] pub struct TileDef where @@ -101,7 +78,6 @@ where } } - #[derive(Serialize, Deserialize, Debug, Inspect, Clone, Copy)] pub struct TileBb { pub x: u8, diff --git a/tiles.rs b/tiles.rs index 179788e..52d5a62 100644 --- a/tiles.rs +++ b/tiles.rs @@ -42,28 +42,6 @@ impl TileLayer for Fg { type SpecificDef = (); } -pub type BgTileId = TileId; -pub type MidTileId = TileId; -pub type FgTileId = TileId; - -impl BgTileId { - pub const DIRT: Self = Self(1, PhantomData); - pub const STONE: Self = Self(2, PhantomData); -} - -impl MidTileId { - pub const DIRT: Self = Self(1, PhantomData); - pub const STONE: Self = Self(2, PhantomData); - pub const TORCH: Self = Self(3, PhantomData); - pub const PLATFORM: Self = Self(4, PhantomData); - pub const PANZERIUM: Self = Self(5, PhantomData); - pub const UNBREAKANIUM: Self = Self(6, PhantomData); -} - -impl FgTileId { - pub const COAL: Self = Self(1, PhantomData); -} - #[derive(Serialize, Deserialize, Inspect)] pub struct TileDef where