major goal: "everything is just an object and voxel-engine just deals with keeping a list of objects for collisions" via voxel-chunks
pending:
voxels.createChunkRadiusStream().pipe(voxels.generateChunkStream()).pipe(game.voxels)
for async chunk loading- switched to the culled mesher so that we can implement texture atlases, which will reduce draw calls by a ton
- implement ambient occlusion after switching to the culled mesher
investigated/completed:
use. UPDATE: on second thought this is kind of mess. I prefer to think instead of things as 'more public' and 'less public', e.g. beginner methods and advanced methods. The core API is grouped together now inside voxel-engine (look up 'external API' in index.js)_
prefixed methods for internaladd. UPDATE: since this isn't an async API (all voxels are already in memory) a stream didn't make sense, so I decided ongame.voxelRange(low, hi).createReadStream()
for bulk read accessgame.blocks()
instead: https://github.com/maxogden/voxel-engine/commit/9ca141ff368ed5d272c67de5ee0cc5d93c509108game.staticPath
that integrates static-assets. UPDATE: waiting on zlib + tar to get integrated into this solution- use voxel-raycast against voxel-chunks. it is implemented for voxel terrain but voxel-chunks need more work before this can happen
switch to gl-matrix (or similar) for vector mathsUPDATE: added here https://github.com/maxogden/voxel-engine/commit/26625ef241707850d171b4eb60be47d0347e0750
I think the question is "what should voxel-engine be?" What functionality should it hold?
It seems like it should have as little implementation as possible, and instead just be an API for different modules and the communication between those modules. Ideally everything could be entirely replaced individually without having to modify the core engine or interfaces between modules.
Some ideas for what modules should be the core engine, with their current implementations if they exist:
SpatialEventEmitter is cool but yeah, it seems like something that should be separate from the actual spatial partitioning algorithm.