lol idk #1

Open
Quaternions wants to merge 826 commits from StrafesNET/strafe-project:master into master
Showing only changes of commit d95549070b - Show all commits

View File

@ -150,23 +150,24 @@ impl IntersectingAttributes{
} }
#[derive(Clone,Copy,id::Id,Hash,Eq,PartialEq)] #[derive(Clone,Copy,id::Id,Hash,Eq,PartialEq)]
pub struct CollisionAttributesId(u32); pub struct CollisionAttributesId(u32);
#[derive(Clone,Default,Hash,Eq,PartialEq)]
pub struct ContactAttributes{
pub contacting:ContactingAttributes,
pub general:GeneralAttributes,
}
#[derive(Clone,Default,Hash,Eq,PartialEq)]
pub struct IntersectAttributes{
pub intersecting:IntersectingAttributes,
pub general:GeneralAttributes,
}
#[derive(Clone,Hash,Eq,PartialEq)] #[derive(Clone,Hash,Eq,PartialEq)]
pub enum CollisionAttributes{ pub enum CollisionAttributes{
Decoration,//visual only Decoration,//visual only
Contact{//track whether you are contacting the object Contact(ContactAttributes),//track whether you are contacting the object
contacting:ContactingAttributes, Intersect(IntersectAttributes),//track whether you are intersecting the object
general:GeneralAttributes,
},
Intersect{//track whether you are intersecting the object
intersecting:IntersectingAttributes,
general:GeneralAttributes,
},
} }
impl CollisionAttributes{ impl CollisionAttributes{
pub fn contact_default()->Self{ pub fn contact_default()->Self{
Self::Contact{ Self::Contact(ContactAttributes::default())
contacting:ContactingAttributes::default(),
general:GeneralAttributes::default()
}
} }
} }