fix overflow caused by ChunkAccess

This commit is contained in:
dags- 2020-02-26 12:15:30 +00:00
parent 25c19d3156
commit 8b58e0fac7
3 changed files with 7 additions and 4 deletions

View File

@ -25,7 +25,7 @@ expansive and inspiring worlds to build and explore in!
_Probably! (to some degree) - TerraForged is designed to work with many of the same world-gen systems _Probably! (to some degree) - TerraForged is designed to work with many of the same world-gen systems
that the majority of block & biome providing mods use. Certain biomes' terrain may not always look that the majority of block & biome providing mods use. Certain biomes' terrain may not always look
exactly as their author designed but should otherwise be compatible. Feel free to report any other exactly as their author designed but should otherwise be compatible. Feel free to report any other
compatibility issues on the issue tracker_ compatibility issues on the issue tracker._
2. "How can I use this on my server?" 2. "How can I use this on my server?"
_When Forge supports it, you can simply set level-type=terraforged in your server.properties file. In _When Forge supports it, you can simply set level-type=terraforged in your server.properties file. In

View File

@ -31,7 +31,5 @@ import net.minecraft.world.chunk.IChunk;
public interface ChunkAccess extends IChunk { public interface ChunkAccess extends IChunk {
default BlockState getState(BlockPos pos) { BlockState getState(BlockPos pos);
return getBlockState(pos);
}
} }

View File

@ -73,6 +73,11 @@ public class ChunkDelegate implements ChunkAccess {
return chunk; return chunk;
} }
@Override
public BlockState getState(BlockPos pos) {
return chunk.getBlockState(pos);
}
@Override @Override
@Nullable @Nullable
public BlockState setBlockState(BlockPos pos, BlockState state, boolean isMoving) { public BlockState setBlockState(BlockPos pos, BlockState state, boolean isMoving) {