Expose collision generation for skeleons for Unreal 4 blueprints. (#1167)

This commit is contained in:
Nick Pruehs 2018-08-30 13:32:39 +02:00 committed by Mario Zechner
parent 77ae166c99
commit b67b2f098a
2 changed files with 5 additions and 1 deletions

View File

@ -169,7 +169,7 @@ void USpineSkeletonRendererComponent::Flush (int &Idx, TArray<FVector> &Vertices
if (Vertices.Num() == 0) return;
SetMaterial(Idx, Material);
CreateMeshSection(Idx, Vertices, Indices, TArray<FVector>(), Uvs, Colors, TArray<FProcMeshTangent>(), false);
CreateMeshSection(Idx, Vertices, Indices, TArray<FVector>(), Uvs, Colors, TArray<FProcMeshTangent>(), bCreateCollision);
Vertices.SetNum(0);
Indices.SetNum(0);

View File

@ -68,6 +68,10 @@ public:
UPROPERTY(Category = Spine, EditAnywhere, BlueprintReadWrite)
FLinearColor Color = FLinearColor(1, 1, 1, 1);
/** Whether to generate collision geometry for the skeleton, or not. */
UPROPERTY(Category = Spine, EditAnywhere, BlueprintReadWrite)
bool bCreateCollision;
virtual void FinishDestroy() override;
protected: