Suggested workflow is to create the component and then add it to an array rather than creating components as part of the array
When an array is used to declare actor components, the component elements that make up the array cannot be edited inside blueprints.
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Test) TArray<UBoxComponent*> Boxes; UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Test) USceneComponent* MyScene;
MyScene = CreateDefaultSubobject<USceneComponent>(TEXT("MyScene")); RootComponent = MyScene; Boxes.SetNum(2); Boxes[0] = CreateDefaultSubobject<UBoxComponent>(TEXT("NewBox1")); Boxes[0]->AttachTo(RootComponent); Boxes[1] = CreateDefaultSubobject<UBoxComponent>(TEXT("NewBox2")); Boxes[1]->AttachTo(RootComponent);
Result:
Transform widget is missing and Details panel is blank so the component cannot be edited through the blueprint
Expected:
BP components that are created as part of an array can be edited through blueprints.
i have this problem UE4CC-Windows-58DC12AF4B97F057BD108FBFF569B2E9_0000
Delay nodes occasionally don't fire the "Completed" output in a nativized build
Undefined sysmbol: typeinfo for AActor when cross-compile linux dedicated server on windows
I am not able to find world outliner how to enable it?
An error occurred while trying to generate project files !?
I can't open my map from the editor.
Head over to the existing Questions & Answers thread and let us know what's up.
9 |
Component | UE - Gameplay - Blueprint |
---|---|
Affects Versions | 4.11 |
Created | Mar 8, 2016 |
---|---|
Resolved | Jul 15, 2016 |
Updated | Jul 14, 2021 |