I am 80% confident in what I think you’re asking me to do in the pseudo code but I can’t do anything on begin play because it all needs to by dynamic.
The items I spawn in the world need to be added to the list and hold reference data on the fly, let me delete actors from the list which deletes the actor in the world and other functions I need.
This is the part I get stuck on. I’ve added actors to a list from begin-play, but that apparently only worked with blueprint objects specifically, not the actor itself and any reference I create there such as an actor variable has no effect. It doesn’t know which actor in the world it is and hold no association.
I’m just going through the tutorial to understand further, but maybe I’m looking at this whole thing the wrong way because the way I’m picturing it is:
- spawn actor in world
- this specific actor is referenced directly in the list UI
- I can click the actors in the list and whichever one I click corresponds to the one in the world.
And I don’t think I want to keep using get all actors of class everytime I spawn one of these actors, because I’m going to be spawning quite a lot.