parent
8f5d1cc6ae
commit
85d1241a48
1 changed files with 6 additions and 8 deletions
|
@ -201,7 +201,7 @@ public class CorePlugin extends PositionPlugin.Listener {
|
|||
|
||||
final Vector3i position = entry.getPosition();
|
||||
|
||||
if (isCore(position)) shouldRefill = true;
|
||||
if (isCore(position) && !isCommandBlockUpdate(entry.getBlock())) shouldRefill = true;
|
||||
}
|
||||
|
||||
public void packetReceived (ClientboundSectionBlocksUpdatePacket packet) {
|
||||
|
@ -212,14 +212,16 @@ public class CorePlugin extends PositionPlugin.Listener {
|
|||
for (BlockChangeEntry entry : entries) {
|
||||
final Vector3i position = entry.getPosition();
|
||||
|
||||
if (isCommandBlockUpdate(entry.getBlock())) continue;
|
||||
|
||||
if (isCore(position)) willRefill = true;
|
||||
if (isCore(position) && !isCommandBlockUpdate(entry.getBlock())) willRefill = true;
|
||||
}
|
||||
|
||||
if (willRefill) shouldRefill = true;
|
||||
}
|
||||
|
||||
public void packetReceived (ClientboundLevelChunkWithLightPacket packet) {
|
||||
shouldRefill = true; // worst fix
|
||||
}
|
||||
|
||||
private boolean isCommandBlockUpdate(int blockState) {
|
||||
return
|
||||
// command block
|
||||
|
@ -241,10 +243,6 @@ public class CorePlugin extends PositionPlugin.Listener {
|
|||
);
|
||||
}
|
||||
|
||||
public void packetReceived (ClientboundLevelChunkWithLightPacket packet) {
|
||||
shouldRefill = true; // TODO: improve, this is probably the worst way to check
|
||||
}
|
||||
|
||||
// ported from chomens bot js
|
||||
private boolean isCore (Vector3i position) {
|
||||
return
|
||||
|
|
Loading…
Reference in a new issue