Fixed /rn not working well with sea level very low.
This commit is contained in:
parent
22f3d0c00e
commit
7d81dc4f5e
|
|
@ -155,6 +155,8 @@ class RestoreNatureProcessingTask implements Runnable
|
|||
|
||||
private void removePlayerLeaves()
|
||||
{
|
||||
if(this.seaLevel < 1) return;
|
||||
|
||||
for(int x = 1; x < snapshots.length - 1; x++)
|
||||
{
|
||||
for(int z = 1; z < snapshots[0][0].length - 1; z++)
|
||||
|
|
@ -174,6 +176,8 @@ class RestoreNatureProcessingTask implements Runnable
|
|||
|
||||
private void fillBigHoles()
|
||||
{
|
||||
if(this.seaLevel < 3) return;
|
||||
|
||||
for(int x = 1; x < snapshots.length - 1; x++)
|
||||
{
|
||||
for(int z = 1; z < snapshots[0][0].length - 1; z++)
|
||||
|
|
@ -235,6 +239,8 @@ class RestoreNatureProcessingTask implements Runnable
|
|||
|
||||
private void reduceStone()
|
||||
{
|
||||
if(this.seaLevel < 1) return;
|
||||
|
||||
for(int x = 1; x < snapshots.length - 1; x++)
|
||||
{
|
||||
for(int z = 1; z < snapshots[0][0].length - 1; z++)
|
||||
|
|
@ -280,6 +286,8 @@ class RestoreNatureProcessingTask implements Runnable
|
|||
|
||||
private void reduceLogs()
|
||||
{
|
||||
if(this.seaLevel < 1) return;
|
||||
|
||||
boolean jungleBiome = this.biome == Biome.JUNGLE || this.biome == Biome.JUNGLE_HILLS;
|
||||
|
||||
//scan all blocks above sea level
|
||||
|
|
@ -525,7 +533,7 @@ class RestoreNatureProcessingTask implements Runnable
|
|||
do
|
||||
{
|
||||
changed = false;
|
||||
for(int y = this.seaLevel - 10; y <= this.seaLevel; y++)
|
||||
for(int y = Math.max(this.seaLevel - 10, 0); y <= this.seaLevel; y++)
|
||||
{
|
||||
for(int x = 1; x < snapshots.length - 1; x++)
|
||||
{
|
||||
|
|
@ -580,6 +588,8 @@ class RestoreNatureProcessingTask implements Runnable
|
|||
|
||||
private void removeDumpedFluids()
|
||||
{
|
||||
if(this.seaLevel < 1) return;
|
||||
|
||||
//remove any surface water or lava above sea level, presumed to be placed by players
|
||||
//sometimes, this is naturally generated. but replacing it is very easy with a bucket, so overall this is a good plan
|
||||
if(this.environment == Environment.NETHER) return;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user