I have a ChunkActor that represents a Chunk of data (voxel terrain) and construct the mesh with the data received. I need a class that will use perlin noise, generate the data and spawn n Actors with thei chunk of data.
But I don’t know how am I supposed to call this “ChunkManager” class. I can sure do “Spawn Actor” in BP after OnClicked (on some buttons), but I’m not sure it’s the way to go because ChunkManager is not an Actor, this is just a normal class and it will generate Actors.
The question is do I have to do ChunkManager : public AActor or is there a better way to do this? Because ChunkManager will not display anything. It will create n ChunkActor.
Use ConstructObject instead of SpawnActor, but don’t use it on Actors because they need processes in SpawnActor
But ConstructObject is just a way to create object in code, right ? Is it possible to create an object directly in blueprint ?
In the editor, I have a class ChunkManager (inherit from UObject). Now I want, in the level BP, to create a variable with ChunkManager type. Is it possible to do that ?
After 2 days I finally decided to use AActor for the ChunkManager. Really useful to use basic event, especially Tick to load the chunk over time and to have a perfect control between generation, framerate and optimization on the fly. After some test, I know now that using AActor for a class doesn’t affect performance or this is too small to be really important compared to the advantages of being able to use them in blueprint.