chore: update to the latest parry api
This commit is contained in:
committed by
Sébastien Crozet
parent
dbefeb0418
commit
7565e5e4ef
@@ -341,7 +341,7 @@ impl DynamicRayCastVehicleController {
|
||||
wheel.raycast_info.ground_object = None;
|
||||
|
||||
if let Some((collider_hit, mut hit)) = hit {
|
||||
if hit.toi == 0.0 {
|
||||
if hit.time_of_impact == 0.0 {
|
||||
let collider = &colliders[collider_hit];
|
||||
let up_ray = Ray::new(source + rayvector, -rayvector);
|
||||
if let Some(hit2) =
|
||||
@@ -362,7 +362,7 @@ impl DynamicRayCastVehicleController {
|
||||
wheel.raycast_info.is_in_contact = true;
|
||||
wheel.raycast_info.ground_object = Some(collider_hit);
|
||||
|
||||
let hit_distance = hit.toi * raylen;
|
||||
let hit_distance = hit.time_of_impact * raylen;
|
||||
wheel.raycast_info.suspension_length = hit_distance - wheel.radius;
|
||||
|
||||
// clamp on max suspension travel
|
||||
@@ -372,7 +372,7 @@ impl DynamicRayCastVehicleController {
|
||||
.raycast_info
|
||||
.suspension_length
|
||||
.clamp(min_suspension_length, max_suspension_length);
|
||||
wheel.raycast_info.contact_point_ws = ray.point_at(hit.toi);
|
||||
wheel.raycast_info.contact_point_ws = ray.point_at(hit.time_of_impact);
|
||||
|
||||
let denominator = wheel
|
||||
.raycast_info
|
||||
|
||||
Reference in New Issue
Block a user