fix some physics lints
This commit is contained in:
parent
13cae4c7c5
commit
168d6708d1
@ -39,9 +39,6 @@ pub struct InputState{
|
||||
controls:strafesnet_common::controls_bitflag::Controls,
|
||||
}
|
||||
impl InputState{
|
||||
pub const fn get_next_mouse(&self)->&MouseState{
|
||||
&self.next_mouse
|
||||
}
|
||||
fn set_next_mouse(&mut self,next_mouse:MouseState){
|
||||
//I like your functions magic language
|
||||
self.mouse=std::mem::replace(&mut self.next_mouse,next_mouse);
|
||||
@ -693,18 +690,18 @@ struct IntersectModel{
|
||||
}
|
||||
|
||||
#[derive(Debug,Clone,Copy,Eq,Hash,PartialEq)]
|
||||
struct ContactCollision{
|
||||
pub struct ContactCollision{
|
||||
face_id:model_physics::MinkowskiFace,
|
||||
model_id:ContactModelId,
|
||||
submesh_id:PhysicsSubmeshId,
|
||||
}
|
||||
#[derive(Debug,Clone,Copy,Eq,Hash,PartialEq)]
|
||||
struct IntersectCollision{
|
||||
pub struct IntersectCollision{
|
||||
model_id:IntersectModelId,
|
||||
submesh_id:PhysicsSubmeshId,
|
||||
}
|
||||
#[derive(Debug,Clone,Eq,Hash,PartialEq)]
|
||||
enum Collision{
|
||||
pub enum Collision{
|
||||
Contact(ContactCollision),
|
||||
Intersect(IntersectCollision),
|
||||
}
|
||||
@ -957,9 +954,6 @@ impl PhysicsContext{
|
||||
pub const fn camera(&self)->PhysicsCamera{
|
||||
self.state.camera
|
||||
}
|
||||
pub const fn get_next_mouse(&self)->&MouseState{
|
||||
self.state.input_state.get_next_mouse()
|
||||
}
|
||||
/// use with caution, this is the only non-instruction way to mess with physics
|
||||
pub fn generate_models(&mut self,map:&map::CompleteMap){
|
||||
self.state.clear();
|
||||
|
Loading…
x
Reference in New Issue
Block a user