Merge branch '1.17'
This commit is contained in:
commit
af368a159d
173 files changed
+2214
-1462
No files matched your search
@@ -512,9 +512,9 @@ public class ScriptCommand
|
||||
{
|
||||
ServerCommandSource source = context.getSource();
|
||||
CarpetScriptHost host = getHost(context);
|
||||
BlockBox area = new BlockBox(a, b);
|
||||
BlockBox area = BlockBox.create(a, b);
|
||||
CarpetExpression cexpr = new CarpetExpression(host.main, expr, source, origin);
|
||||
int int_1 = area.getBlockCountX() * area.getBlockCountY() * area.getBlockCountZ();
|
||||
int int_1 = area.getBlockCountX() * area.getBlockCountY() * area.getBlockCountZ(); // X Y Z
|
||||
if (int_1 > CarpetSettings.fillLimit)
|
||||
{
|
||||
Messenger.m(source, "r too many blocks to evaluate: " + int_1);
|
||||
@@ -524,11 +524,11 @@ public class ScriptCommand
|
||||
CarpetSettings.impendingFillSkipUpdates.set(!CarpetSettings.fillUpdates);
|
||||
try
|
||||
{
|
||||
for (int x = area.minX; x <= area.maxX; x++)
|
||||
for (int x = area.getMinX(); x <= area.getMaxX(); x++)
|
||||
{
|
||||
for (int y = area.minY; y <= area.maxY; y++)
|
||||
for (int y = area.getMinY(); y <= area.getMaxY(); y++)
|
||||
{
|
||||
for (int z = area.minZ; z <= area.maxZ; z++)
|
||||
for (int z = area.getMinZ(); z <= area.getMaxZ(); z++)
|
||||
{
|
||||
try
|
||||
{
|
||||
@@ -561,7 +561,7 @@ public class ScriptCommand
|
||||
{
|
||||
ServerCommandSource source = context.getSource();
|
||||
CarpetScriptHost host = getHost(context);
|
||||
BlockBox area = new BlockBox(a, b);
|
||||
BlockBox area = BlockBox.create(a, b);
|
||||
CarpetExpression cexpr = new CarpetExpression(host.main, expr, source, origin);
|
||||
int int_1 = area.getBlockCountX() * area.getBlockCountY() * area.getBlockCountZ();
|
||||
if (int_1 > CarpetSettings.fillLimit)
|
||||
@@ -570,22 +570,22 @@ public class ScriptCommand
|
||||
return 1;
|
||||
}
|
||||
|
||||
boolean[][][] volume = new boolean[area.getBlockCountX()][area.getBlockCountY()][area.getBlockCountZ()];
|
||||
boolean[][][] volume = new boolean[area.getBlockCountX()][area.getBlockCountY()][area.getBlockCountZ()]; //X then Y then Z got messedup
|
||||
|
||||
BlockPos.Mutable mbpos = origin.mutableCopy();
|
||||
ServerWorld world = source.getWorld();
|
||||
|
||||
for (int x = area.minX; x <= area.maxX; x++)
|
||||
for (int x = area.getMinX(); x <= area.getMaxX(); x++)
|
||||
{
|
||||
for (int y = area.minY; y <= area.maxY; y++)
|
||||
for (int y = area.getMinY(); y <= area.getMaxY(); y++)
|
||||
{
|
||||
for (int z = area.minZ; z <= area.maxZ; z++)
|
||||
for (int z = area.getMinZ(); z <= area.getMaxZ(); z++)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (cexpr.fillAndScanCommand(host, x, y, z))
|
||||
{
|
||||
volume[x-area.minX][y-area.minY][z-area.minZ]=true;
|
||||
volume[x-area.getMinX()][y-area.getMinY()][z-area.getMinZ()]=true;
|
||||
}
|
||||
}
|
||||
catch (CarpetExpressionException e)
|
||||
@@ -640,7 +640,7 @@ public class ScriptCommand
|
||||
{
|
||||
if (volume[x][y][z])
|
||||
{
|
||||
mbpos.set(x+area.minX, y+area.minY, z+area.minZ);
|
||||
mbpos.set(x+area.getMinX(), y+area.getMinY(), z+area.getMinZ());
|
||||
if (replacement == null || replacement.test(
|
||||
new CachedBlockPosition( world, mbpos, true)))
|
||||
{
|
||||
@@ -668,7 +668,7 @@ public class ScriptCommand
|
||||
{
|
||||
if (volume[x][y][z])
|
||||
{
|
||||
mbpos.set(x+area.minX, y+area.minY, z+area.minZ);
|
||||
mbpos.set(x+area.getMinX(), y+area.getMinY(), z+area.getMinZ());
|
||||
Block blokc = world.getBlockState(mbpos).getBlock();
|
||||
world.updateNeighbors(mbpos, blokc);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user