I have a method where I need to pass in an actor to get some information from said actor. This is also a method that I want to be able to use in blueprints, or rather let others use in blueprints. when I have a
UFUNCTION(BlueprintCallable, Category = Logic)
decorator above the method declaration in the header, the compiler goes nuts on me with the following error:
Error 1 error C2275: ‘TWeakObjectPtr<AActor,FWeakObjectPtr,FIndexToObject>’ : illegal use of this type as an expression
Is this something we’re not supposed to be able to do? And if so, is there a “proper” way of passing objects around by reference that would let me use the method via blueprints?