Description

Naming an SCS component variable something like "My Scene" results in a component template UObject named "My Scene_GEN_VARIABLE" (space included).

This causes the property editor/details view to fail to assign an object instance value to an editinline property reference if the component type contains one as a class member.

Steps to Reproduce
  1. Create a new, blank C++ project.
  2. Add a new UActorComponent-based subclass (C++) - e.g. UMyActorComponent.
  3. In the .h file / class declaration add a new class type and UPROPERTY() as follows:
    // Add this class def
    UCLASS(EditInlineNew)
    class UMyTestSubObjectType : public UObject
    {
    	GENERATED_BODY()
    };
    
    // Add 'Blueprintable'
    UCLASS(Blueprintable, ClassGroup=(Custom), meta=(BlueprintSpawnableComponent))
    class UMyActorComponent : public UActorComponent
    {
    	GENERATED_BODY()
    
    public:	
    	// Sets default values for this component's properties
    	UMyActorComponent();
    
            // Add this property
    	UPROPERTY(EditAnywhere, Instanced)
    	TObjectPtr<UMyTestSubObjectType> TestSubobject;
    
            // ...
    };
    
  4. Compile C++ and launch the editor / live coding to get the new C++ class.
  5. Create a new Actor-based Blueprint class.
  6. In the Blueprint editor, add a new component of the type added in C++ above.
  7. Rename the component to include one or more spaces in the name (e.g. "My Test Actor").
  8. Select the component. In the details tab, find the property added above and attempt to create a new instance via the drop-down.
  9. Note that the value remains set to "None."
    Expected result: The value updates to reflect the new instance being assigned to the property.

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-55663 in the post.

2
Login to Vote

Fixed
ComponentUE - Gameplay - Components
Affects Versions4.275.05.1
Target Fix5.1.1
Fix Commit23517415
Main Commit23519395
Release Commit23517415
CreatedFeb 28, 2018
ResolvedDec 14, 2022
UpdatedFeb 4, 2023
View Jira Issue