mirror of
https://github.com/Minestom/Minestom.git
synced 2025-01-19 14:41:34 +01:00
Fix block break packet using resultant block (#996)
This commit is contained in:
parent
12543acf5e
commit
a78309a2b2
@ -199,7 +199,7 @@ public class InstanceContainer extends Instance {
|
||||
new BlockHandler.PlayerDestroy(block, this, blockPosition, player));
|
||||
// Send the block break effect packet
|
||||
PacketUtils.sendGroupedPacket(chunk.getViewers(),
|
||||
new EffectPacket(2001 /*Block break + block break sound*/, blockPosition, resultBlock.stateId(), false),
|
||||
new EffectPacket(2001 /*Block break + block break sound*/, blockPosition, block.stateId(), false),
|
||||
// Prevent the block breaker to play the particles and sound two times
|
||||
(viewer) -> !viewer.equals(player));
|
||||
}
|
||||
@ -625,4 +625,4 @@ public class InstanceContainer extends Instance {
|
||||
var dispatcher = MinecraftServer.process().dispatcher();
|
||||
dispatcher.createPartition(chunk);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user