Fixed second render chunk counting issue

This commit is contained in:
Joshua Barretto 2020-04-23 17:09:53 +01:00
parent 2a6a19f7ef
commit 1a4c7f46f4

View File

@ -1989,9 +1989,11 @@ impl<V: RectRasterableVol> Terrain<V> {
if *n >= chunks.len() {
None
} else {
*n += 1;
let pos = focus_chunk + rpos;
Some(chunks.get(&pos).map(|c| (pos, c)))
Some(chunks.get(&pos).map(|c| {
*n += 1;
(pos, c)
}))
}
})
.filter_map(|x| x);