x

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"

is there any way to get a delay in a function

is there any way to get some sort of a delay in a function dosent matter how just need a delay i dont care how complicated it is but i need it real bad

Product Version: UE 4.15
Tags:
more ▼

asked Apr 15 '17 at 10:45 PM in Blueprint Scripting

avatar image

678GUY
141 33 32 38

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

3 answers: sort voted first

Functions are executed in a synchronous manner and everything waits until the function returns its output. Their purpose is to return a result in exactly one frame. If you don't have any outputs from the function (and why would you purposely wait N time to get an output?) feel free to swap it for a Custom Event where you can use latent stuff.

more ▼

answered Apr 16 '17 at 12:53 AM

avatar image

neelix32
154 2 3 7

avatar image 678GUY Apr 16 '17 at 01:29 PM

yes but with a custom event i cant get an output from a node

avatar image neelix32 Apr 16 '17 at 05:14 PM

you can always store the intermediate result in a variable instead of using an output from a function

avatar image 678GUY Apr 16 '17 at 06:15 PM

yeah but i need an exection output not a var

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

I recommend you to create a macro if you need to have a delay, their is no way (from my experience) to get delay node inside function.

more ▼

answered Apr 15 '17 at 11:10 PM

avatar image

Xosh project
366 3 6 15

avatar image 678GUY Apr 15 '17 at 11:11 PM

how does a macro help me?

avatar image Xosh project Apr 16 '17 at 03:28 AM

take a look on this -> https://docs.unrealengine.com/latest/INT/Engine/Blueprints/UserGuide/Macros/

But as neelix32 say, you can push your function inside a custom event.

avatar image 678GUY Apr 16 '17 at 01:30 PM

i can push it inside a function but i cant get an output from it

avatar image Xosh project Apr 18 '17 at 04:54 AM

Please take a look on this -> https://docs.unrealengine.com/latest/INT/Engine/Blueprints/UserGuide/Macros/

You'll find exactly how to have input and output with macro. You have a LOT of image that explain exactly how it work.

avatar image 678GUY Apr 18 '17 at 10:10 AM

i know how to use macros but they cant have the 3 nodes that i need i need to cast to a widget and a macro cant do that

avatar image Xosh project Apr 18 '17 at 04:53 PM

From what I know, you can cast from macro when you want without any problem. Like Vaei say, open a new question to let us know what you try to achieve because I'm pretty sure this isn't that hard to achieve with custom event/macros.

If you want send a link of the new question here in the comment.

avatar image 678GUY Apr 18 '17 at 04:57 PM

i know i can cast but i cant get the refrence for the widget with get all widgets of class

avatar image Xosh project Apr 19 '17 at 04:19 PM

You can maybe create a variable «Object» and get your object like this. Also please follow my advice and create a new question to expose your new problem about casting and macros (or the thing you need exacly).

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

Unless I'm misunderstanding your question, there is an actual "Delay" node.

more ▼

answered Apr 16 '17 at 12:28 AM

avatar image

Vaei
596 28 24 52

avatar image Xosh project Apr 16 '17 at 03:29 AM

He want delay node inside function.

avatar image Vaei Apr 16 '17 at 08:43 PM

Oh, just split it into two functions with a delay in between. Question is too vague to say more than that, OP is asking how to do something that can't be done, that when phrased another way might have a solution for what he's trying to do, but there's no info to answer in that manner.

avatar image 678GUY Apr 16 '17 at 08:56 PM

that wont help me because i need delay inside a funtion i cant split it into 2

avatar image Vaei Apr 16 '17 at 09:01 PM

You can't have a delay in a function. Maybe post a new question with what you're actually trying to achieve and you'll get help that does help you. :)

avatar image Xosh project Apr 18 '17 at 04:52 AM

Actually this is a good answer.

(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