9
0
mirror of https://github.com/Xiao-MoMi/Custom-Crops.git synced 2025-12-23 08:59:28 +00:00

Update MaxSprinklersPerChunk.java

This commit is contained in:
XiaoMoMi
2022-05-25 10:15:59 +08:00
committed by GitHub
parent 1ca8eb5028
commit a47a0b7a4c

View File

@@ -24,10 +24,10 @@ public class MaxSprinklersPerChunk {
Label_out: Label_out:
for (int i = 0; i < 16; ++i) { for (int i = 0; i < 16; ++i) {
for (int j = 0; j < 16; ++j) { for (int j = 0; j < 16; ++j) {
final Location square = chunkLocation.clone().add((double)i, 0.0, (double)j); final Location square = chunkLocation.clone().add((double)(i+0.5), 0.5, (double)(j+0.5));
for (int k = minY; k <= maxY; ++k) { for (int k = minY; k <= maxY; ++k) {
square.add(0.0, 1.0, 0.0); square.add(0.0, 1.0, 0.0);
if(IAFurniture.getFromLocation(square.clone().add(0.5,0.5,0.5), world)){ if(IAFurniture.getFromLocation(square, world)){
if (n++ > maxAmount) { if (n++ > maxAmount) {
break Label_out; break Label_out;
} }