I have a question concerning the genration procedural voxel world.
I currently have generated a world with the noise of a simplex in 2D ( axis x ; y ) and I used statics mesh instanced for my cubes, which measures 25 cm, the problems is that I can not generate more than 650 k cube before bug… exceeded 650k I bug more and more, that is what I could used as a component to generated a lot more cube without bug ? I tried the procedural meshes but I bug 50 times more x) thank you for your help !
I think you want to make game like minecraft?
But even game like minecraft, cubes are just spawn when IT NEED TO BE SEEN
It means you can store the voxel data in memmory,but just spawn cubes at the voxel location which can be seen by player,such as these:
The cubes is on surface
The cubes is close to player
After player change his location,or player destroy some cubes, new cubes should be spawn at the new surface
i make a chunk and i use a set max draw distance in my blueprint but the distance is not enough large, it is for ca that I’m looking for something other than the instanced static mesh, but if you want me to said that even the block to the rear of the camera should disappear, I’ll try that
Yes, I think you have to manage your cubes to make more cubes not instanced. There must be many cubes in 650k cubes that not need to instance at one frame.
But spawn/destroy one instance of instanced mesh is slow depends on the number of meshes.So I think you should try UProceduralMeshComponent
to directly create cubes with vertex.
I would work on something that would save block data to memory, and (un) load blocks depending on position relative to the player. Or (un) load them depending on if they can be seen. But if you do the former, then I would recommend setting a mist or fog around the player and also unload blocks outside of a certain radius.