How can I expose a UObject to both be extended by a blueprint and allow that blueprint to be assigned to a variable of another blueprint?
To better illustrate, let’s say I have an object to both have some logic and store animations:
UCLASS(Blueprintable, BlueprintType)
class MYGAME_API UAnimationHandler : public UObject
{
GENERATED_BODY()
public:
bool RunAnimation(const EAnimation Animation);
private:
// ... Some pointers to animations
};
And I have an actor that holds a reference to it:
UCLASS()
class MYGAME_API AMyActor : public AActor
{
GENERATED_BODY()
private:
UPROPERTY(Category = "Animation", EditAnywhere, BlueprintReadWrite, meta = (AllowPrivateAccess = "true"))
class UAnimationHandler* AnimationHandler;
};
Then I create a blueprint for the handler populating the animations.
And now I want to assign the handler blueprint to a blueprint of AMyActor.
When opening the box to assign AnimationHandler there are zero options and trying to drag and drop did not help.
Is there a way to make this work? Is there some configuration missing?