@@ -616,17 +616,15 @@ impl Vehicle {
616616 // AWD/4WD: both axles drive, weight transfer doesn't reduce total drive grip
617617 let cg_height_abs = self . chassis . cg_height . abs ( ) ;
618618 let weight_transfer_sign: f64 = match self . chassis . drive_type {
619- chassis:: DriveTypes :: FWD => 1.0 , // weight shifts away from front drive axle → reduces traction
620- chassis:: DriveTypes :: RWD => -1.0 , // weight shifts toward rear drive axle → increases traction
621- chassis:: DriveTypes :: AWD
622- | chassis:: DriveTypes :: FourWD => 0.0 , // net zero effect on total drive traction
619+ chassis:: DriveTypes :: FWD => 1.0 , // weight shifts away from front drive axle → reduces traction
620+ chassis:: DriveTypes :: RWD => -1.0 , // weight shifts toward rear drive axle → increases traction
621+ chassis:: DriveTypes :: AWD | chassis:: DriveTypes :: FourWD => 0.0 , // net zero effect on total drive traction
623622 } ;
624- let max_trac_accel = self . chassis . wheel_fric_coef
625- * self . chassis . drive_axle_weight_frac
626- * uc:: ACC_GRAV
627- / ( 1.0 * uc:: R
628- + weight_transfer_sign * cg_height_abs * self . chassis . wheel_fric_coef
629- / self . chassis . wheel_base ) ;
623+ let max_trac_accel =
624+ self . chassis . wheel_fric_coef * self . chassis . drive_axle_weight_frac * uc:: ACC_GRAV
625+ / ( 1.0 * uc:: R
626+ + weight_transfer_sign * cg_height_abs * self . chassis . wheel_fric_coef
627+ / self . chassis . wheel_base ) ;
630628 let prev_speed = * self . state . speed_ach . get_stale ( || format_dbg ! ( ) ) ?;
631629 let max_trac_speed = prev_speed + ( max_trac_accel * dt) ;
632630 self . state
0 commit comments