Interfaced BlueprintNativeEvent's not appearing in Blueprint when all params are UPARAM(ref)
I think I've found a bug when using a UInterface with a BlueprintNativeEvent that is trying to pass in non-const refs.
I need the refs to be editable by the blueprint, which means I need to declare the params with UPARAM(ref) to prevent them from being output values only.
Inside my UInterface I declared the following:
Then in my class I provide the ApplyBonus_Implementation(...).
However after adding the UPARAM(ref)'s to function, it no longer appears for implementation in any of the blueprinted objects.
Now the weird part of this is, the event only disappears if ALL of the params are defined as UPARAM(ref)'s. If one param is not a UPARAM, the function shows up in the BP for implementation. I then tested the following cases (result is in the category meta)
I've also tested with non-interfaced versions of the above, which all work as intended. So it seems to be related to interfaces in particular.
Regarding my intended usage; I'd prefer to not to create an event that is MyFunc(float in, float& out), so if there are any other ways to handle this, I'm open to suggestions.
asked Apr 06 '18 at 09:21 AM in C++ Programming
Follow this question
Once you sign in you will be able to subscribe for any updates here