From 066418d7b2214473c10a1a794e6787d02b73dda1 Mon Sep 17 00:00:00 2001 From: DBotThePony Date: Thu, 18 Jul 2024 20:16:50 +0700 Subject: [PATCH] https://i.dbotthepony.ru/2024/07/18/attachment-133_1.gif --- .../kotlin/ru/dbotthepony/mc/otm/data/RecipeWrapperCodec.kt | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/main/kotlin/ru/dbotthepony/mc/otm/data/RecipeWrapperCodec.kt b/src/main/kotlin/ru/dbotthepony/mc/otm/data/RecipeWrapperCodec.kt index e9f950796..6f25b5ff1 100644 --- a/src/main/kotlin/ru/dbotthepony/mc/otm/data/RecipeWrapperCodec.kt +++ b/src/main/kotlin/ru/dbotthepony/mc/otm/data/RecipeWrapperCodec.kt @@ -21,7 +21,6 @@ fun > RecipeSerializer.codec(context: Codec2RecipeSerializer<*> val buffer = FriendlyByteBuf(UnpooledByteBufAllocator.DEFAULT.heapBuffer()) buffer.writeResourceLocation(input.recipe.id) toNetwork(buffer, input.recipe) - buffer.writerIndex(0) buffer.readerIndex(0) val array = ByteBuffer.allocate(buffer.readableBytes()) buffer.readBytes(array) @@ -38,7 +37,6 @@ fun > RecipeSerializer.codec(context: Codec2RecipeSerializer<*> it.position(0) val buffer = FriendlyByteBuf(UnpooledByteBufAllocator.DEFAULT.heapBuffer()) buffer.writeBytes(it) - buffer.writerIndex(0) buffer.readerIndex(0) Pair(RecipePair(fromNetwork(buffer.readResourceLocation(), buffer)!!, JsonObject()), ops.empty()) }