Description

UWheeledVehicleComponent calculates the Suspension settings only when the physics state is first created.

When CoM is set through the editor, the vehicle is constructed with the appropriate offset and everything works fine.

When CoM is set at runtime, the suspension data is not recalculated properly, and the vehicle exhibits unexpected behavior.

As a fix for [Link Removed], a delegate was added to BodyInstance that will notify when the mass properties are updated. This addresses a few issues, but doesn't address the suspension setup. Recalculating the suspension setup (and potentially other vehicle settings that are dependent on weight) when the delegate is called should fix the issue.

Steps to Reproduce
  1. Download, Build, and Open the attached project.
  2. Open the Default map (if not already open).
  3. Observe the set of trucks falling on the right.
  4. Observe the set of trucks moving then turning on the left.

(In both cases, the left truck of each pair has Center Of Mass Offset set in Editor and the right truck has it set On Begin Play).

Expected: Each truck's movement should be consistent with its partner's movement.

Actual: The trucks with CoM set On Begin Play act differently than those set in Editor.

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-39820 in the post.

0
Login to Vote

Fixed
ComponentUE - Simulation - Physics
Affects Versions4.144.15
Target Fix4.16
Fix Commit3290753
Main Commit3362661
CreatedDec 15, 2016
ResolvedFeb 7, 2017
UpdatedApr 27, 2018
View Jira Issue