mirror of
https://github.com/GeyserMC/Geyser.git
synced 2025-04-17 19:12:14 +02:00
Merge branch 'block-item-mixin-fix' into custom-item-api-v2
This commit is contained in:
commit
c510204f6e
1 changed files with 4 additions and 0 deletions
|
@ -49,6 +49,10 @@ public class BlockPlaceMixin {
|
|||
@Inject(method = "place", at = @At(value = "INVOKE", target = "Lnet/minecraft/world/level/Level;playSound(Lnet/minecraft/world/entity/Entity;Lnet/minecraft/core/BlockPos;Lnet/minecraft/sounds/SoundEvent;Lnet/minecraft/sounds/SoundSource;FF)V"))
|
||||
private void geyser$hijackPlaySound(BlockPlaceContext blockPlaceContext, CallbackInfoReturnable<InteractionResult> callbackInfoReturnable,
|
||||
@Local BlockPos pos, @Local Player player, @Local(ordinal = 1) BlockState placedState) {
|
||||
if (player == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
GeyserSession session = GeyserImpl.getInstance().connectionByUuid(player.getUUID());
|
||||
if (session == null) {
|
||||
return;
|
||||
|
|
Loading…
Add table
Reference in a new issue