From 1702924c95172b0cc086f709885749fbf15f871e Mon Sep 17 00:00:00 2001 From: basaigh <53559772+basaigh@users.noreply.github.com> Date: Thu, 3 Oct 2024 17:23:35 +0100 Subject: [PATCH] 24w39a --- .../protocol/codec/MinecraftCodec.java | 4 +-- .../data/game/entity/type/EntityType.java | 32 ++++++++++++++----- .../level/ClientboundSetTimePacket.java | 15 +++++---- 3 files changed, 35 insertions(+), 16 deletions(-) diff --git a/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/codec/MinecraftCodec.java b/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/codec/MinecraftCodec.java index 547fb171..8ee6bccb 100644 --- a/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/codec/MinecraftCodec.java +++ b/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/codec/MinecraftCodec.java @@ -210,9 +210,9 @@ import org.geysermc.mcprotocollib.protocol.packet.status.serverbound.Serverbound public class MinecraftCodec { public static final PacketCodec CODEC = PacketCodec.builder() - .protocolVersion((1 << 30) | 210) + .protocolVersion((1 << 30) | 211) .helper(MinecraftCodecHelper::new) - .minecraftVersion("24w38a") + .minecraftVersion("24w39a") .state(ProtocolState.HANDSHAKE, MinecraftPacketRegistry.builder() .registerServerboundPacket(ClientIntentionPacket.class, ClientIntentionPacket::new) ) diff --git a/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/data/game/entity/type/EntityType.java b/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/data/game/entity/type/EntityType.java index 46bc7fb5..f134ca7a 100644 --- a/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/data/game/entity/type/EntityType.java +++ b/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/data/game/entity/type/EntityType.java @@ -3,47 +3,56 @@ package org.geysermc.mcprotocollib.protocol.data.game.entity.type; import lombok.Getter; public enum EntityType { + ACACIA_BOAT, + ACACIA_CHEST_BOAT, ALLAY, AREA_EFFECT_CLOUD, ARMADILLO, ARMOR_STAND, ARROW(true), AXOLOTL, + BAMBOO_CHEST_RAFT, + BAMBOO_RAFT, BAT, BEE, + BIRCH_BOAT, + BIRCH_CHEST_BOAT, BLAZE, BLOCK_DISPLAY, - BOAT, BOGGED, BREEZE, BREEZE_WIND_CHARGE(true), CAMEL, CAT, CAVE_SPIDER, - CHEST_BOAT, + CHERRY_BOAT, + CHERRY_CHEST_BOAT, CHEST_MINECART, CHICKEN, COD, COMMAND_BLOCK_MINECART, COW, CREEPER, + DARK_OAK_BOAT, + DARK_OAK_CHEST_BOAT, DOLPHIN, DONKEY, DRAGON_FIREBALL(true), DROWNED, EGG(true), ELDER_GUARDIAN, - END_CRYSTAL, - ENDER_DRAGON, - ENDER_PEARL(true), ENDERMAN, ENDERMITE, + ENDER_DRAGON, + ENDER_PEARL(true), + END_CRYSTAL, EVOKER, EVOKER_FANGS, EXPERIENCE_BOTTLE(true), EXPERIENCE_ORB, EYE_OF_ENDER, FALLING_BLOCK, + FIREBALL(true), FIREWORK_ROCKET(true), FOX, FROG, @@ -64,18 +73,23 @@ public enum EntityType { ITEM, ITEM_DISPLAY, ITEM_FRAME, - OMINOUS_ITEM_SPAWNER, - FIREBALL(true), + JUNGLE_BOAT, + JUNGLE_CHEST_BOAT, LEASH_KNOT, LIGHTNING_BOLT, LLAMA, LLAMA_SPIT(true), MAGMA_CUBE, + MANGROVE_BOAT, + MANGROVE_CHEST_BOAT, MARKER, MINECART, MOOSHROOM, MULE, + OAK_BOAT, + OAK_CHEST_BOAT, OCELOT, + OMINOUS_ITEM_SPAWNER, PAINTING, PANDA, PARROT, @@ -99,11 +113,13 @@ public enum EntityType { SLIME, SMALL_FIREBALL(true), SNIFFER, - SNOW_GOLEM, SNOWBALL(true), + SNOW_GOLEM, SPAWNER_MINECART, SPECTRAL_ARROW(true), SPIDER, + SPRUCE_BOAT, + SPRUCE_CHEST_BOAT, SQUID, STRAY, STRIDER, diff --git a/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/packet/ingame/clientbound/level/ClientboundSetTimePacket.java b/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/packet/ingame/clientbound/level/ClientboundSetTimePacket.java index bf84e1d4..cb47a7ee 100644 --- a/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/packet/ingame/clientbound/level/ClientboundSetTimePacket.java +++ b/protocol/src/main/java/org/geysermc/mcprotocollib/protocol/packet/ingame/clientbound/level/ClientboundSetTimePacket.java @@ -11,17 +11,20 @@ import org.geysermc.mcprotocollib.protocol.codec.MinecraftPacket; @With @AllArgsConstructor public class ClientboundSetTimePacket implements MinecraftPacket { - private final long worldAge; - private final long time; + private final long gameTime; + private final long dayTime; + private final boolean tickDayTime; public ClientboundSetTimePacket(ByteBuf in, MinecraftCodecHelper helper) { - this.worldAge = in.readLong(); - this.time = in.readLong(); + this.gameTime = in.readLong(); + this.dayTime = in.readLong(); + this.tickDayTime = in.readBoolean(); } @Override public void serialize(ByteBuf out, MinecraftCodecHelper helper) { - out.writeLong(this.worldAge); - out.writeLong(this.time); + out.writeLong(this.gameTime); + out.writeLong(this.dayTime); + out.writeBoolean(this.tickDayTime); } }