When an array of custom UObjects is defined in an actor component class, blueprint instances of the component class cannot update the array elements. Array elements only update inside the blueprint, which changes all placed instances. This prevents separate instances from having separate arrays.

No - behavior occurs in 4.13.2 and 4.14.0

Steps to Reproduce
  1. Open UE4 Editor (any project)
  2. Add code to project based on Object (MyObject)
  3. Set UCLASS specifier with the following:
    (BlueprintType, EditInlineNew, DefaultToInstanced)
  1. Add code to project based on ActorComponent (MyActorComponent)
  2. Add TArray of UMyObject to MyActorComponent.h public
     UPROPERTY(EditAnywhere, Instanced, Category = "MyCategory") TArray<class UMyObject*> ArrayOfMyObjects;
  1. Add code to project based on MyObject (SecondObject)
  2. Compile code and make new blueprint based on Actor (ActorBP)
  3. Add instance of My Actor Component to ActorBP
  4. Select My Actor Coponent and add two elements to ArrayOfMyObjects
  5. Set One element to MyObject and the other SecondObject
  6. Place instance of MyActor into the level
  7. Select My Actor Component in actor details
  8. Click the field for element 0 (MyObject) and change to SecondObject

The element value will be unchanged and still show MyObject

Element value can be set on instances of the blueprint

Have Comments or More Details?

Head over to the existing Questions & Answers thread and let us know what's up.

Login to Vote

ComponentUE - Gameplay - Components
Affects Versions4.
Target Fix5.0
Fix Commit19031036
Main Commit19140863
CreatedNov 20, 2016
ResolvedFeb 17, 2022
UpdatedMar 7, 2022