void Start() { mainCamera = Camera.main; mapChunkCreation = new VoxelMapData(perlinGen, vGenConfig); mapChunkMeshing = new VoxelMapFormat(meshGen, hilbertIndicesShader, mapChunkCreation, vGenConfig); offsetIndex = firstIndex; StartCoroutine(generateChunks()); }
void Start() { mainCamera = Camera.main; mapChunkCreation = new VoxelMapData(perlinGen); mapChunkMeshing = new VoxelMapFormat(meshGen, mapChunkCreation); offsetIndex = 0; if (createSponge) { mapChunkCreation.createSponge(); } else { mapChunkCreation.callPerlinMapGenKernel(mapOffset(offsetIndex)); } mapChunkMeshing.callFaceGenKernel(); mapChunkMeshing.callFaceSumKernel(); createChunks = true; }