Hello! I study the logic of blueprints. My task is simple, but it’s still not clear to me. In general, there is an array of static meshes, when I press a button, I need to delete one of the static meshes, let’s say the last one in the array by index, and so on with each click until the last index is equal to -1. I created a logic that is logical for me, but the indexes are removed and the static mesh is not. Please tell me what I need to do with this logic
the indexes are removed and the static mesh is not.
How do you know they are not being removed? You’ve added Static Mesh Components and assigned them Static Meshes.
Even if you empty the array, the Static Mesh Components are here to stay, until you remove them, too, of course.
If you wanted to get rid of the Static Mesh Components, add them to an array. Use that array to destroy the components:
And then clean up.
1 Like
Thank you very much for your help, now everything works as it should!
1 Like