Removing TaggedComponent from actors
This commit is contained in:
parent
010c3e29bf
commit
97aae5bea4
|
@ -8,7 +8,7 @@
|
|||
#include "ProceduralFoliageComponent.h"
|
||||
|
||||
#include "Carla/Vegetation/VegetationManager.h"
|
||||
|
||||
#include "Game/TaggedComponent.h"
|
||||
|
||||
static FString GetVersionFromFString(const FString& String)
|
||||
{
|
||||
|
@ -692,6 +692,14 @@ AActor* AVegetationManager::CreateFoliage(const FFoliageBlueprint& BP, const FTr
|
|||
|
||||
AActor* Actor = GetWorld()->SpawnActor<AActor>(BP.SpawnedClass,
|
||||
Transform.GetLocation(), Transform.Rotator());
|
||||
|
||||
TArray<UTaggedComponent*> TaggedComponents;
|
||||
Actor->GetComponents(TaggedComponents);
|
||||
for (UTaggedComponent* Component: TaggedComponents)
|
||||
{
|
||||
Component->DestroyComponent();
|
||||
}
|
||||
|
||||
if (SpawnScale <= 1.01f && SpawnScale >= 0.99f)
|
||||
Actor->SetActorScale3D(Transform.GetScale3D());
|
||||
else
|
||||
|
|
|
@ -97,32 +97,32 @@ public:
|
|||
void UpdatePoolBasePosition();
|
||||
|
||||
public:
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
bool DebugMaterials {false};
|
||||
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
float HideMaterialDistance {500.0f};
|
||||
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
float ActiveActorDistance {500.0f};
|
||||
|
||||
//Filters for debug
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
bool SpawnBushes {true};
|
||||
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
bool SpawnTrees {true};
|
||||
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
bool SpawnRocks {true};
|
||||
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
bool SpawnPlants {true};
|
||||
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
float SpawnScale {1.0f};
|
||||
|
||||
UPROPERTY(Category = "CARLA Vegetation Spwaner", EditDefaultsOnly)
|
||||
UPROPERTY(Category = "CARLA Vegetation Spawner", EditDefaultsOnly)
|
||||
int32 InitialPoolSize {10};
|
||||
|
||||
/// @}
|
||||
|
|
Loading…
Reference in New Issue