Can't expose delegate on spawn

I have declared the following delegate in my C++ class, then use it as a member variable like so:

DECLARE_DYNAMIC_DELEGATE_OneParam(FVectorDelegate, FVector&, output);

UPROPERTY(BlueprintReadWrite, EditAnywhere, Meta = (ExposeOnSpawn))
FVectorDelegate VectorDelegate;

Unfortunately when using the ExposeOnSpawn UPROPERTY specifier, it appears as a pin when constructing the object but does not actually get bound.


For now I can get around this by setting it after construction, but it would be nicer if I could just set it via the construction pin like I can for other variable types.

Hey miracle7-

I’m not sure I understand what you’re reporting. When I add the code provided, I am able to access the Set node as shown in your second screenshot. Can you explain what you mean by “set it via the construction pin”? Is the Construct Vector History node a code function as well?

I am using the Construct Object From Class node to create an instance of my C++ class (UVectorHistory).

I want to set the delegate using the exposed pin as shown in my first screenshot, but it doesn’t work. That is what I am reporting.

Second screenshot using Set node is a workaround for this bug.

Thank you for the clarification. I was able to reproduce the behavior you described and have entered a report here: Unreal Engine Issues and Bug Tracker (UE-44977) . You can track the report’s status as the issue is reviewed by our development staff. Please be aware that this issue may not be prioritized or fixed soon.