Created
February 7, 2023 22:17
-
-
Save Eko450-eng/4f09bc255d7c9acef99bc272ceb7f095 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class TeleportPlayerC2SPacket { | |
public static void receive(MinecraftServer server, ServerPlayerEntity player, ServerPlayNetworkHandler handler, PacketByteBuf buf, PacketSender resPonseSender){ | |
BlockPos destination = buf.readBlockPos(); | |
player.teleport(destination.getX(), destination.getY(), destination.getZ(), true); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment