Explorar o código

Fix nan errors when using VehicleBody

(cherry picked from commit 1b8cbcf94648b7baeb3def5464f6f67509081134)
Rafał Mikrut %!s(int64=4) %!d(string=hai) anos
pai
achega
24d03afc9b
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      scene/3d/vehicle_body.cpp

+ 1 - 0
scene/3d/vehicle_body.cpp

@@ -389,6 +389,7 @@ VehicleWheel::VehicleWheel() {
 	m_suspensionRelativeVelocity = 0;
 	m_clippedInvContactDotSuspension = 1.0;
 	m_raycastInfo.m_isInContact = false;
+	m_raycastInfo.m_suspensionLength = 0.0;
 
 	body = NULL;
 }