The function takes two arrays that are variables in the myCharacter blueprint, and returns a new array. However, I cant set the variables as the inputs to the function within the BP, probably because the target is the parent class, not myCharacter object itself. The myCharacter object is not visible in C++, as far as I can see. Any advice would be much appreciated! Cheers…
If I understand you correctly… you have a ParentClass to your MyCharacter class. This ParentClass has a Blueprint accessible function DeleteHandHold that that takes in two TArrays as parameters and then returns a TArray. When you put DeleteHandHold in the Blueprint of your MyCharacter class, it isn’t accepting the TArrays called ReceiveHandHold and ActiveHandHold as parameter inputs to the node.
What you could try is to make a wrapper function in your MyCharacter class.
Then you would use that node in the MyCharacter Blueprint.
There might be something else odd happening with the ParentClass function but it’s hard to say without seeing your whole implementation. If this error is some Blueprint functionality error… I’m not sure. This wrapper method should work though.
I just opened a different project which has a C++ header and cpp file for the character class, not just a parent class. It works as I was expecting it to do in the first place. The parameter arrays are on the other side of the node in blueprint, and they accept “get” vales for array variables in the blueprint. I’m going to try your method too, thanks for the reply…
Turns out this was caused by using pass-by-reference in the function parameters. In order to make blueprint variables pass by reference, see here;
However, not sure that solves anything going in the other direction (making a C++ function for use in blueprints), my input variables were on the right hand side of the node in blueprint, and would only take getters, not setters.