i have a simple spawn mechanism that requires me to clear instances and attached actors. But for some weird reason, the array loop does not destroy all attached actors. It seems like the array does not fill properly.
Cache the result of pure functions to a local variable, and connect that to loop macros
Pure functions will get executed in every iteration of the loop
In your case, get attached actors will get called once in every loop, so after destroying the first actor, the next time the array returned by the function will be different, causing your loop to potentially miss some actors since every evaluation might return them in different order