Let’s say I have this node placed in the custom editor. Now let’s say I have an actor which have an access to this node (obtained with CustomGraph->GetNodesOfClass()) and want to access UFUNCTION or UPROPERTY of this node from regular blueprint.
The problem is I can’t see them in regular blueprint but the rest of UObject-derived classes gives visibility of UFUNCTION and UPROPERTY pretty well.
tl;dr
UEdGraphNode derived classes UFUNCTIONs are not showing in blueprints.
Other UObject derived classes (for example UBlueprintFunctionLibrary) UFUNCTIONs are showing in blueprints.
Why is that so?
A little update. A problem is still here, but I’ve picked up some more data on issue.
Turns out you CAN use UEdGraphNode’s UPROPERTY and UFUNCTION definitions in blueprints, but you can’t have an access to them in context menu.
Looks like it just doesn’t get captured by reflection system.
I’ve derived blueprint from C++ UEdGraphNode class and added the function with the same name as in C++.
System alerted me that such function exists and base function appeared in Functions tab. I was able to drag it and use in other blueprints.
This workaround, however, can’t be used with UPROPERTY in same way since you can’t provoke variable to throw an override alert.
So yeah, here’s the issue, some UObject-derived classes doesn’t get their UPROPERTYs and UFUCTIONs in reflection system. Is there way to modify UEdGraphNode to register U-stuff in reflection system?
I’ve just tried to call Cast to CustomNodeBase and realized it doesn’t get to context menu as well.
Looks like UEdGraphNode class family are really not intended for blueprint use.
That’s a sad thing to know since I would need to make ugly UObject wrappers with setters and getters to use it in blueprint…
erf :-/
I would suggest to make a c++ blueprintLibrary instead of UObject wrapper, that would be cleaner ( less messy… ) ( take a UObject cast it to you class, and return value )