Jorrit Rouwe il y a 2 ans
Parent
commit
a3d5318748
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      Samples/Tests/General/ConveyorBeltTest.cpp

+ 1 - 1
Samples/Tests/General/ConveyorBeltTest.cpp

@@ -96,7 +96,7 @@ void ConveyorBeltTest::OnContactAdded(const Body &inBody1, const Body &inBody2,
 		Vec3 body2_angular_surface_velocity = body2_angular? inBody2.GetRotation() * cLocalSpaceAngularVelocity : Vec3::sZero();
 
 		// Note that the angular velocity is the angular velocity around body 1's center of mass, so we need to add the linear velocity of body 2's center of mass
-		Vec3 body2_linear_surface_velocity = body2_angular? (inBody2.GetCenterOfMassPosition() - inBody1.GetCenterOfMassPosition()).Cross(body2_angular_surface_velocity) : Vec3::sZero();
+		Vec3 body2_linear_surface_velocity = body2_angular? Vec3(inBody2.GetCenterOfMassPosition() - inBody1.GetCenterOfMassPosition()).Cross(body2_angular_surface_velocity) : Vec3::sZero();
 		
 		// Calculate the relative angular surface velocity
 		ioSettings.mRelativeSurfaceVelocity = body2_linear_surface_velocity;