In my project I want to get a reference to a class and spawn & despawn it whenever I want.
For example create actor, wait, spawn it in x,y,z, wait again, despawn it, etc…
But I don’t find a way to create an instance of a class without spawning it in. Is there a way to create an instance of a class without spawning it in?
Or at least, is it possible to save somehow the class itself, so I can spawn something from a class without knowing beforehand what the class is (for example is I have object A from class C, but during programming I don’t know what class C is, so is there a way to save class C so I can spawn more object from class C)
You can create pools of actors and use/unuse those doing your game/project.
These get created by their Class Name, so you can reference those class in the same way as spawn - maybe an Array of your classes which you could then choose from.