Why when I use the spawn actor do I need it to run twice? augmented reality

Hi Everyone.
I have a query about augmented reality and the spawn actor node

If the spawn actor node is executed only once with the position references of the recognized image, the actor does not appear, it needs to be executed at least 2 times (I had to validate the actor so that the Spawn event would stop when it already existed in the world ), I don’t know if it does it to set the internal variables or what is the logic behind it, however I would like to know what is the reason for this behavior.

Thank you very much in advance and have a good evening.

It’s too small to read, really, but I think you make the spawn call here?

By that time, these values

will always be from the end of the array, because you have finished loop by now.

I tried to modify the find variable before the event was called so that the actor could be generated only with an execution of the SpawnActor node, however the only way that works for me is to check the validity of the actor and then limit the Spawn event with the branch.

there the SpawnActor node is executed only once, but the actor cannot be created in the world.

Sorry, it’s so small, almost impossible to read.

Are you trying to spawn one of each class?

Then you need the spawn call in the loop.

I’m sorry, I have attached slightly larger images.

This is the first mode, where everything works perfectly, only I’m intrigued that the SpawnActor node needs to be executed more than once for the actor to be created.

This is the second way, where I try to make it run only once but the actor is not created when recognizing the image.

It’s on tick (!)

It’s like calling that spawn event, on every frame ( 120 times per second ), with the last class from your map.

I’m really not sure what the meaning of that is.

If I had to leave the “Get All AR Geometries By Class” node in the event tick because it didn’t work for me outside of there.