Hi, I have a Blueprint extending from Actor class. In Begin Play some function calls are made, but when it arrives to a certain Delay, not first one, it stops there. It’s very weird because using BP flow debug I see that previous Delays in this Blueprint are executed and countdowns are shown when flow arrives to them, but at mentioned certain Delay it just stops and countdown is not shown.
This Blueprint actor is never destroyed, so that’s not cause of stop. Modifying Delay time also doesn’t show any change. What could be causing this misterious stop? It’s UE4 4.2.
Is this inside a function? You could use a timer to call Choose spawn Points.
Sorry I cant help further this could be a bug. So you could try to redo this sequence.
But to test theory you would have to delete sequence and then close and reopen project. Of course setup sequence again to see if it still is having same issue.
If it does you could escalate this to a bug report unless someone else has an answer.
Thanks for suggestion, but delays are used here to delay a continuate set of function calls with inputs and outputs, which SetTimers can’t hold.
Also, I used to have this exact structure of Begin Play and all function calls and delays in Level Blueprint’s EventGraph, where it worked as expected, not stopping at a Delay, but then in this Blueprint’s EventGraph (extending from Actor class) weird problem happens.
I’ve tried to reproduce this but have not yet been able. You mention that this is not inside a flow control loop, and that’s only situation where a delay shouldn’t work that I’m aware of. I may need to see what’s going on inside custom function Spawn Short Cactus, as well as what rest of this Blueprint looks like behind Delay that’s causing problem.
You mention using Sequence, for example. Are you using multiple Sequence nodes, and is this only place where a Delay does not work? If you take out Delay, does rest of Blueprint proceed? Thanks!
OK, here is solution: using Tick event instead of Begin Play, with a Branch to filter a bool to avoid repetition, makes whole thing work as expected. It’s a bit puzzling, looks like something unexpected in Blueprint system, but, anyway, my case here is solved.
I’m glad you were able to get it working, but I’m still not sure what would have caused that in first place. If this issue resurfaces, please let us know so we can continue investigating. Thanks!
I’ve just recently run into this on 4.13.0 - In my game mode I had a 0.05 sec delay that would start but never end. delay’s purpose was to add a break between http requests I was doing - so: when http request got a result, it would trigger a delegate event, do some stuff, wait 0.05 sec then do another request.
I added print strings either side of delay - prior one would print but not one after. So it obviously wasn’t getting retriggered else prior string would print more than once. I tried to replace it with a SetTimerByEvent but that also never seemed to fire.
In end I didn’t need to have that break between http requests, so I just removed delay in my case… but it’s still a bit unsettling.
Notes on Delay in blueprints.
For a given event there is only one delay timer. When event gets called and then hits a delay, delay starts. If another call to same event happens, while delay is pending, and encounters any delay in event, it gets ignored.
For example if you can equip a weapon to left and/or right hand, and you have an event to equip weapon, and it takes a left or right flag, and you do a delay after creating Actor so actor gets instanced on clients before equipping to a hand (in multiplayer this would be a rep-notify and you wanted to wait for clients to get actor before rep notify happens), and then to set player up you make two weapons and equip them, it will fail.
first weapon gets created, and delay starts. Almost immediately after, second weapon gets created, and delay gets hit and ignores second chain of execution, because delay timer for event is already delaying. Then delay times out, and first weapon gets equipped, and second weapon gets ignored and not equipped.
This will happen whether there is only one delay node in event, or one delay node for left and one delay node for right in same event.
This is intended design of event architecture in blueprints.
solution in our multiplayer VR game is to have separate events for each equip variable that delays and then equips. Like this…