Hi there,
We have an avatar that sits in a vehicle that is controlled by an animation blueprint that sets hand and feet positions using IK and other transforms all from a data struct received from C++.
If the vehicle crashes then we eject the avatar from the vehicle in a ragdoll state by enabling physics on the skeletal mesh component and adding an impulse.
I’m writing an instant replay system that currently correctly captures the all the relevant vehicle transform data and the avatar position derived from that except for when it is ejected from the vehicle.
I looked through the code of the sequencer and found that the it gets it’s data from USkeletalMeshComponent::GetSpaceBases so I am now capturing that while the avatar is in the ejected ragdoll state. For replaying back the captured on the avatar I found that there is USkeletalMeshComponent::GetEditableSpaceBases or potentially more appropriately USkeletalMeshComponent::UpdateKinematicBonesToAnim, which takes the SpaceBases (TArray) as a parameter.
My question is how can I stop the animation blueprint from controlling the avatar and only have the UpdateKinematicBonesToAnim affect the avatar, or else what is the correct way of setting the skeletal mesh to my captured space bases? I looked into what happens when physics is enabled for the skeletal mesh but it seems that the avatar all the UpdateAnimation code is still run but that the physics logic overrides it (I’m assuming for the purposes of allowing blending in/out of physics).
Many thanks