Child Components Spawning At Origin

Aha! I found it.

Setting the relative location to 0 in OnConstruction fixed the problem. I don’t know if this is the right way to do it, but it worked.


void APAWN_2DCharacter::OnConstruction(const FTransform& Transform)
{
Super::OnConstruction(Transform);
staticMesh->SetRelativeLocation(FVector(0));
hitBox->SetRelativeLocation(FVector(0));
}

1 Like