Set Root Component in Pickup

This commit is contained in:
baz 2023-09-12 23:37:49 +01:00
parent 480cfb0530
commit 62ac0e7496
1 changed files with 1 additions and 2 deletions

View File

@ -18,8 +18,7 @@ APickup::APickup()
SphereComponent = CreateDefaultSubobject<USphereComponent>(TEXT("SphereComponent"));
SphereComponent->SetSphereRadius(25.0f, true);
SphereComponent->SetCollisionEnabled(ECollisionEnabled::QueryAndProbe);
SphereComponent->SetupAttachment(RootComponent);
SetRootComponent(SphereComponent);
PointLightComponent = CreateDefaultSubobject<UPointLightComponent>(TEXT("PointLightComponent"));
PointLightComponent->SetupAttachment(RootComponent);