The component is not attached to the socket via C++ code

I got a few questions about your code.

  1. How do you know if it’s not attached? Remember that sometimes properties declared in C++ are not visible in Blueprints.
    Try to change your UPROPERTY(EditAnywhere) to UPROPERTY(EditAnywhere, BlueprintReadWrite) to visualize it on editor.

  2. Are you sure “GetMesh()” is initialized by the time you set up attachments to it?
    May be something to confirm.

1 Like