From d98b6cf224749cd2d304e4c0e62e503dc07e90e5 Mon Sep 17 00:00:00 2001 From: Thom van den Akker Date: Thu, 12 Dec 2024 17:11:05 +0100 Subject: [PATCH] Write collection size, otherwise results in deserialization failure (#10530) Missing size int to the serialization --- .../com/minecolonies/core/datalistener/DiseasesListener.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/com/minecolonies/core/datalistener/DiseasesListener.java b/src/main/java/com/minecolonies/core/datalistener/DiseasesListener.java index 1610eef22ea..388d02331db 100644 --- a/src/main/java/com/minecolonies/core/datalistener/DiseasesListener.java +++ b/src/main/java/com/minecolonies/core/datalistener/DiseasesListener.java @@ -71,6 +71,7 @@ public static void sendGlobalDiseasesPackets(final ServerPlayer player) byteBuf.writeResourceLocation(disease.id()); byteBuf.writeComponent(disease.name()); byteBuf.writeInt(disease.rarity()); + byteBuf.writeInt(disease.cureItems().size()); for (final ItemStorage cureItem : disease.cureItems()) { StandardFactoryController.getInstance().serialize(byteBuf, cureItem);