UStructs do support inheritence for me, at least when I code them up, they are not supported in blueprints.
To Wit the folowing will compile
USTRUCT(BlueprintType,
meta = (DisplayName = " Test",
Keywords = “Test”))
struct IWBPLIB_API FIW_Test {
GENERATED_USTRUCT_BODY()
/*
parent struct
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite)
int32 m1;
FIW_Test() {
m1 = 5;
}
};
USTRUCT(BlueprintType,
meta = (DisplayName = “Test2”,
Keywords = “Test2”))
struct IWBPLIB_API FIW_Test2 : public FIW_Test {
GENERATED_USTRUCT_BODY()
/*
child struct
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite)
int32 m20;
FIW_Test2() {
m20 = 10;
}
};
and the following does work, with the TArray for Test accepting the Structure for Test2
FIW_Test2 t2;
FIW_Test t1;
t2.m20 = t1.m1;
TArray<FIW_Test> t1Ar;
t1Ar.Add(t2);
I’m using 4.10