I am trying to move a camera around an object to different locations/rotations and then take a picture and store the picture. The loop works (I’ve been able to print out a message each time the loop executes), I am able to take a picture (but only at the last position)… I thought I needed to delay a bit for the position to change and render a new scene to take the next picture but the loop seems to hit the delay node and then just go back to the next iteration before the delay is completed… thoughts?
Here is my Event Graph → Working with ForLoop posted by Harimau84 | blueprintUE | PasteBin For Unreal Engine
Delay doesn’t work in loops, unless you write your own macro that includes it.
Just double click the foreach node, it will take you to the macro. Do not edit it
Save as a new copy, then include your delay node in the macro. Voila
I believe that relying on delays might not be the most effective approach to solve this problem. In my humble opinion, it would be beneficial to set up a timer for calling that function.
This way, you can precisely define the time interval between each iteration and halt the timer once the iterations are completed. I hope the blueprint below will assist you further.