Pad chunksnapshots with empty section (avoid y=256 exceptions)
This commit is contained in:
parent
ed229cee93
commit
34348a6d16
18 changed files with 72 additions and 72 deletions
|
|
@ -137,10 +137,10 @@ public class MapChunkCache116 extends AbstractMapChunkCache {
|
|||
this.biomebase = new Object[COLUMNS_PER_CHUNK];
|
||||
this.sectionCnt = worldheight / 16;
|
||||
/* Allocate arrays indexed by section */
|
||||
this.section = new Section[this.sectionCnt];
|
||||
this.section = new Section[this.sectionCnt+1];
|
||||
|
||||
/* Fill with empty data */
|
||||
for (int i = 0; i < this.sectionCnt; i++) {
|
||||
for (int i = 0; i <= this.sectionCnt; i++) {
|
||||
this.section[i] = empty_section;
|
||||
}
|
||||
|
||||
|
|
@ -163,9 +163,9 @@ public class MapChunkCache116 extends AbstractMapChunkCache {
|
|||
this.inhabitedTicks = 0;
|
||||
}
|
||||
/* Allocate arrays indexed by section */
|
||||
this.section = new Section[this.sectionCnt];
|
||||
this.section = new Section[this.sectionCnt+1];
|
||||
/* Fill with empty data */
|
||||
for (int i = 0; i < this.sectionCnt; i++) {
|
||||
for (int i = 0; i <= this.sectionCnt; i++) {
|
||||
this.section[i] = empty_section;
|
||||
}
|
||||
/* Get sections */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue