diff --git a/src/graphics.rs b/src/graphics.rs index 224948a..12bdd52 100644 --- a/src/graphics.rs +++ b/src/graphics.rs @@ -2,7 +2,7 @@ use std::borrow::Cow; use std::collections::{HashSet,HashMap}; use strafesnet_common::map; use strafesnet_common::integer; -use strafesnet_common::model::{self, ColorId, MapVertexId, NormalId, PolygonIter, PositionId, RenderConfigId, TextureCoordinateId, VertexId}; +use strafesnet_common::model::{self, ColorId, NormalId, PolygonIter, PositionId, RenderConfigId, TextureCoordinateId, VertexId}; use wgpu::{util::DeviceExt,AstcBlock,AstcChannel}; use crate::model_graphics::{self,IndexedGraphicsMeshOwnedRenderConfig,IndexedGraphicsMeshOwnedRenderConfigId,GraphicsMeshOwnedRenderConfig,GraphicsModelColor4,GraphicsModelOwned,GraphicsVertex}; diff --git a/src/model_physics.rs b/src/model_physics.rs index 6612d5b..2002113 100644 --- a/src/model_physics.rs +++ b/src/model_physics.rs @@ -201,10 +201,6 @@ impl PhysicsMesh{ Self::unit_cube() } #[inline] - pub const fn mesh_data(&self)->&PhysicsMeshData{ - &self.data - } - #[inline] pub const fn complete_mesh(&self)->&PhysicsMeshTopology{ &self.complete_mesh } diff --git a/src/physics.rs b/src/physics.rs index edc35b3..f448a0f 100644 --- a/src/physics.rs +++ b/src/physics.rs @@ -1066,7 +1066,7 @@ impl PhysicsContext{ //check for collision starts let mut aabb=aabb::Aabb::default(); state.body.grow_aabb(&mut aabb,state.time,collector.time()); - aabb.inflate(state.style.hitbox.halfsize); + aabb.inflate(data.hitbox_mesh.halfsize); //common body let relative_body=VirtualBody::relative(&Body::default(),&state.body).body(state.time); data.bvh.the_tester(&aabb,&mut |convex_mesh_id|{ @@ -1447,11 +1447,11 @@ fn run_teleport_behaviour(wormhole:&Option,models mod test{ use super::*; fn test_collision_axis_aligned(relative_body:Body,expected_collision_time:Option