Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

[4.6.1, 4.7.0p8] - Set by Ref doesn't work on interface function parameter


There is a problem with setting by reference an interface function input parameter.

You can reproduce the issue;

Step 1: Create a new interface, create a new function, add a Boolean input parameter, and set Pass-by-reference true.

alt text

Step 2: Create a new actor BP, add the interface to this BP.

Step 3: Create the event you created in the interface.

Step 4: Drag the Boolean parameter, and type "set by ref". When the Set Boolean (by Ref) node is created, set the value to True. - (So, whatever Boolean parameter we pass to this function will be set to true.)

Step 5: Compile this BP, and add an instance to the scene.

alt text

Step 6: Create an actor based BP (or select if you have any) on your scene.

Step 7: Create a new actor variable, make it public, go back to the scene, and set this variable to the BP you created in Step 2.

Step 8: Create a new Boolean variable, and make it public. Make a call to the interface function, and pass the Boolean parameter to this function.

alt text

When you execute and debug the interface, you can clearly see that the Boolean parameter is passed successfully, set to true in function scope, but somehow its value is ignored when the interface function looses execution scope and returns to the caller function.

You can try this workflow as a BP function, or within an another BP with no Interface at all, and see that it works. Somehow fails to work as an interface!

EDIT: Today, I double checked the issue with different variable types (integer, float, etc.) as interface function parameters. Same result; they do not work at all :(

Kind Regards,

Product Version: Not Selected
screenshot_01.png (92.9 kB)
screenshot_02.png (189.5 kB)
screenshot_03.png (47.5 kB)
more ▼

asked Feb 23 '15 at 07:08 PM in Bug Reports

avatar image

92 10 16 18

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

3 answers: sort voted first

Hi Dynamo,

The problem is not directly related to interface. An event cannot return any value, neither by value, not by reference. Only function can return values.

If the function from the interface is implemented as a function (in its own graph, not on the event graph) the reference parameter is handled properly. Probably you need to add a dummy output parameter to the signature in the interface.

Sorry for troubles. A proper warning was just added.


more ▼

answered Apr 29 '15 at 01:57 AM

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Hi Dynamo,

Thank you for your report. I was able to reproduce this and have entered a bug report, UE-10836 to be assessed by the development staff. As a workaround for now, use cast nodes and custom functions to create direct communication between the blueprints you need to pass by reference between instead of using a blueprint interface.

more ▼

answered Feb 25 '15 at 06:51 PM

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Thanks kaziu, your answer solved my problem! ^ ^

more ▼

answered Apr 29 '15 at 10:38 AM

avatar image

1 1 1

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question