From 107eb688ebe2b00aa408541c3d36d736d649e329 Mon Sep 17 00:00:00 2001 From: micle Date: Sat, 29 May 2021 17:14:49 +0100 Subject: [PATCH] Fixed double packet sending on single-player and LAN worlds. --- .../com/micle/totemofreviving/items/TotemOfRevivingItem.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/com/micle/totemofreviving/items/TotemOfRevivingItem.java b/src/main/java/com/micle/totemofreviving/items/TotemOfRevivingItem.java index 0fe9153..9929a28 100755 --- a/src/main/java/com/micle/totemofreviving/items/TotemOfRevivingItem.java +++ b/src/main/java/com/micle/totemofreviving/items/TotemOfRevivingItem.java @@ -55,6 +55,7 @@ public class TotemOfRevivingItem extends Item { @Override @OnlyIn(Dist.CLIENT) public ActionResult use(World world, PlayerEntity player, Hand hand) { + if (!world.isClientSide) { return super.use(world, player, hand); } if (player.isCrouching()) { TotemOfReviving.INSTANCE.sendToServer(new C2SRequestTotemTarget(player.getUUID(), hand)); } else {