mirror of
https://github.com/Noratrieb/game-wip-dontplay.git
synced 2026-01-14 19:55:02 +01:00
more
This commit is contained in:
parent
840e869e4a
commit
41efc35b39
2 changed files with 0 additions and 48 deletions
24
src/tiles.rs
24
src/tiles.rs
|
|
@ -3,22 +3,6 @@ use std::{fmt::Debug, marker::PhantomData};
|
||||||
use egui_inspect::{derive::Inspect, Inspect};
|
use egui_inspect::{derive::Inspect, Inspect};
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
|
|
||||||
#[derive(Inspect, PartialEq, Eq)]
|
|
||||||
pub struct TileId<Layer>(pub u16, PhantomData<Layer>);
|
|
||||||
|
|
||||||
impl<Layer> Copy for TileId<Layer> {}
|
|
||||||
impl<Layer> Clone for TileId<Layer> {
|
|
||||||
fn clone(&self) -> Self {
|
|
||||||
Self(self.0, PhantomData)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
impl<Layer> Debug for TileId<Layer> {
|
|
||||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
|
||||||
loop {}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#[derive(Serialize, Deserialize, Inspect)]
|
#[derive(Serialize, Deserialize, Inspect)]
|
||||||
pub struct TileDef
|
pub struct TileDef
|
||||||
where
|
where
|
||||||
|
|
@ -27,14 +11,6 @@ where
|
||||||
//ADD pub blend_graphic: String,
|
//ADD pub blend_graphic: String,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Inspect, Default, Serialize, Deserialize)]
|
|
||||||
pub struct MidDef {
|
|
||||||
/// Platform behavior: Horizontally passable, vertically passable upwards
|
|
||||||
pub platform: bool,
|
|
||||||
/// Collision bounding box
|
|
||||||
pub bb: Option<TileBb>,
|
|
||||||
}
|
|
||||||
|
|
||||||
impl Debug for TileDef
|
impl Debug for TileDef
|
||||||
where
|
where
|
||||||
{
|
{
|
||||||
|
|
|
||||||
24
tiles.rs
24
tiles.rs
|
|
@ -3,22 +3,6 @@ use std::{fmt::Debug, marker::PhantomData};
|
||||||
use egui_inspect::{derive::Inspect, Inspect};
|
use egui_inspect::{derive::Inspect, Inspect};
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
|
|
||||||
#[derive(Inspect, PartialEq, Eq)]
|
|
||||||
pub struct TileId<Layer>(pub u16, PhantomData<Layer>);
|
|
||||||
|
|
||||||
impl<Layer> Copy for TileId<Layer> {}
|
|
||||||
impl<Layer> Clone for TileId<Layer> {
|
|
||||||
fn clone(&self) -> Self {
|
|
||||||
Self(self.0, PhantomData)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
impl<Layer> Debug for TileId<Layer> {
|
|
||||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
|
||||||
loop {}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#[derive(Serialize, Deserialize, Inspect)]
|
#[derive(Serialize, Deserialize, Inspect)]
|
||||||
pub struct TileDef
|
pub struct TileDef
|
||||||
where
|
where
|
||||||
|
|
@ -27,14 +11,6 @@ where
|
||||||
//ADD pub blend_graphic: String,
|
//ADD pub blend_graphic: String,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Inspect, Default, Serialize, Deserialize)]
|
|
||||||
pub struct MidDef {
|
|
||||||
/// Platform behavior: Horizontally passable, vertically passable upwards
|
|
||||||
pub platform: bool,
|
|
||||||
/// Collision bounding box
|
|
||||||
pub bb: Option<TileBb>,
|
|
||||||
}
|
|
||||||
|
|
||||||
impl Debug for TileDef
|
impl Debug for TileDef
|
||||||
where
|
where
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue