Download

Delay in a function

Hi, I’ve just started playing around with functions and I’m trying to convert a system I’ve built based around a retriggerable delay into a function.
However, I am unable to do so and get the following error message:
“Error Delay contains a latent call, which cannot exist outside of the event graph”

Is there a way around this? Or is the only solution to put everything the delay triggers into the function and leave the delay out of the function?

Thanks,
Teed

A function is supposed to finish immediately (and may return a value), you can’t use delay in a function.

Best way I can think around it (without seeing your function) would be to fire off everything in front of the delay in your function , then delay and call the other portion in another function, event, macro or something…

you might have to get a touch creative but anything is doable in blueprints so good luck…

Thanks for the replies!
Guess I’m going to be getting creative then…!

Use custom events (in Event Graph) instead of functions.

Dude it’s been 8 years I think they got it by now