I want to make sure I understand the relationship between member variables defined in C++ with values assigned from Blueprint Editor.
-
First, I created a class called
FPSObjectiveActor
which has a member variableUPROPERTY(VisibleAnywhere, Category = "Components") UStaticMeshComponent* MeshComp;
And in the class constructor, I did the following
MeshComp = CreateDefaultSubobject<UStaticMeshComponent>(TEXT("MeshComp"));
-
Second, I created a blueprint called
BP_Objective
derived fromFPSObjectiveActor
. -
Third, I opened the Blueprint Editor for
BP_Objective
, clickedMeshComp
shown on the Component Tree, and finally changed the Static Mesh fromNone
to one of the available options in the drop down list.
QUESTION
Is changing Static Mesh from None
to one of the available options the same as repointing MeshComp
pointer from its default object (obtained from CreateDefaultSubobject<UStaticMeshComponent>(TEXT("MeshComp"));
) to another object assigned in the Blueprint Editor?