voxeliq
voxeliq copied to clipboard
Fix all negative values for chunk & block accessors.
- [ ] Fix all negative values for chunk & block accessors.
- [ ] Check all accessors & remove unneeded ones.
- [ ] Write unit tests for accessors.
Fixed a few bits with: https://github.com/raistlinthewiz/voxeliq/commit/c0c0d41822d8b4c9ab11b4e7038236c1a8384fd4
File Chunk.cs, Method CalculateHeightIndexes()
has bug on for LowestEmptyBlockOffset that some time value will be 255 ( would be 0 for correct)
That because this line:
this.LowestEmptyBlockOffset--;
should be fixed to: if(this.LowestEmptyBlockOffset > 0) this.LowestEmptyBlockOffset--;
because bytes will be calculate to 255 instead of 0
ps. That action will fixed the issue currentChunk was null in RecacheChunks()