(Really sorry for the weird accent, I’m not that good at english…)
As you can see in the video, those scene components spawned though different methods work a quite different from each other, and I want to make it rotates without moving in the air weirdly like that.
I’m almost sure that this is a bug with the engine, and I want to know if there is any workaround for this problem. Please share your experience about this situation…
Here is the code that I used to spawn those components via c++ :
if (USpineRigBoneDriverComponent* BoneDriverComp = NewObject<USpineRigBoneDriverComponent>(this, CompName)) {
FTransform Transform = TargetComponent->GetSkeletonAnimationComp()->GetBoneWorldTransform(TCHAR_TO_UTF8(*BoneNameString));
FAttachmentTransformRules Rule = FAttachmentTransformRules::KeepWorldTransform;
BoneDriverComp->SetWorldTransform(Transform);
BoneDriverComp->BoneName = BoneNameString;
//Setting for collision stabilization
BoneDriverComp->BodyInstance.PositionSolverIterationCount = 32;
BoneDriverComp->BodyInstance.VelocitySolverIterationCount = 4;
BoneDriverComp->BodyInstance.bUseCCD = true;
BoneDriverComp->BodyInstance.CustomSleepThresholdMultiplier = 3;
BoneDriverComp->BodyInstance.StabilizationThresholdMultiplier = 3;
BoneDriverComp->RegisterComponentWithWorld(Owner->GetWorld());
BoneDriverComp->AttachToComponent(this, Rule);
Owner->AddInstanceComponent(BoneDriverComp);
RigBoneDrivers.Add(Bone, BoneDriverComp);
}