Fix panic when the world is stepped with dt = 0

This commit is contained in:
Sébastien Crozet
2022-04-28 13:04:14 +02:00
parent 95418c218b
commit fd12d76102

View File

@@ -93,12 +93,12 @@ impl IntegrationParameters {
/// The ERP coefficient, multiplied by the inverse timestep length.
pub fn erp_inv_dt(&self) -> Real {
self.erp / self.dt
self.erp * self.inv_dt()
}
/// The joint ERP coefficient, multiplied by the inverse timestep length.
pub fn joint_erp_inv_dt(&self) -> Real {
self.joint_erp / self.dt
self.joint_erp * self.inv_dt()
}
/// The CFM factor to be used in the constraints resolution.