How to attach spring arm to the turret mesh?

Spring amr is attached to root component, but i want to attach it to the turret mesh. How can i get this component from parent class?

SpringArm = CreateDefaultSubobject(TEXT(“Spring Arm”));
SpringArm->SetupAttachment(What should i write here?);

If you make the TurretMesh protected (or provide a public getter) you’ll be able to use it there i.e.

SpringArm->SetupAttachment(TurretMesh);

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms