Skip to content

Commit

Permalink
1133 velocity patch (#1578)
Browse files Browse the repository at this point in the history
* 1337 velocity patch

* 1133 velocity patch
  • Loading branch information
cattyngmd authored Jul 1, 2024
1 parent d8a8468 commit 83e5a84
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@ public void onPacketReceive(PacketReceiveEvent event) {

if (dig.getAction() == DiggingAction.FINISHED_DIGGING) {
// Not unbreakable
if (block.getType().getHardness() != -1.0f && !event.isCancelled()) {
if (!block.getType().isAir() && block.getType().getHardness() != -1.0f && !event.isCancelled()) {
player.compensatedWorld.startPredicting();
player.compensatedWorld.updateBlock(dig.getBlockPosition().getX(), dig.getBlockPosition().getY(), dig.getBlockPosition().getZ(), 0);
player.compensatedWorld.stopPredicting(dig);
Expand Down

0 comments on commit 83e5a84

Please sign in to comment.