From 619049c11f19dc218a6b12a476d897bfcb0be6b1 Mon Sep 17 00:00:00 2001 From: Quaternions Date: Wed, 21 Feb 2024 02:48:41 -0800 Subject: [PATCH] unneeded --- src/physics.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/physics.rs b/src/physics.rs index 16884b0..a21d5bf 100644 --- a/src/physics.rs +++ b/src/physics.rs @@ -1150,10 +1150,9 @@ fn set_velocity_cull(body:&mut Body,touching:&mut TouchingState,models:&PhysicsM set_velocity(body,touching,models,hitbox_mesh,v); culled } -fn set_velocity(body:&mut Body,touching:&TouchingState,models:&PhysicsModels,hitbox_mesh:&HitboxMesh,mut v:Planar64Vec3)->Planar64Vec3{ +fn set_velocity(body:&mut Body,touching:&TouchingState,models:&PhysicsModels,hitbox_mesh:&HitboxMesh,mut v:Planar64Vec3){ touching.constrain_velocity(models,hitbox_mesh,&mut v); body.velocity=v; - v } fn set_acceleration_cull(body:&mut Body,touching:&mut TouchingState,models:&PhysicsModels,hitbox_mesh:&HitboxMesh,a:Planar64Vec3)->bool{ //This is not correct but is better than what I have @@ -1170,10 +1169,9 @@ fn set_acceleration_cull(body:&mut Body,touching:&mut TouchingState,models:&Phys set_acceleration(body,touching,models,hitbox_mesh,a); culled } -fn set_acceleration(body:&mut Body,touching:&TouchingState,models:&PhysicsModels,hitbox_mesh:&HitboxMesh,mut a:Planar64Vec3)->Planar64Vec3{ +fn set_acceleration(body:&mut Body,touching:&TouchingState,models:&PhysicsModels,hitbox_mesh:&HitboxMesh,mut a:Planar64Vec3){ touching.constrain_acceleration(models,hitbox_mesh,&mut a); body.acceleration=a; - a } fn teleport(body:&mut Body,touching:&mut TouchingState,models:&PhysicsModels,style:&StyleModifiers,hitbox_mesh:&HitboxMesh,point:Planar64Vec3)->MoveState{