diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml
index 564e5e3..b4ff8c7 100644
--- a/.idea/jarRepositories.xml
+++ b/.idea/jarRepositories.xml
@@ -6,11 +6,31 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -21,6 +41,11 @@
+
+
+
+
+
diff --git a/pom.xml b/pom.xml
index 02c3bff..279b583 100644
--- a/pom.xml
+++ b/pom.xml
@@ -13,23 +13,31 @@
-
- opencollab
- https://repo.opencollab.dev/maven-snapshots/
-
-
minecraft-libraries
Minecraft Libraries
https://libraries.minecraft.net
+
+
+ CollabNet
+ https://repo.opencollab.dev/main/
+
+
+ CollabNetSnapshots
+ https://repo.opencollab.dev/maven-snapshots/
+
+
+ CollabNetReleases
+ https://repo.opencollab.dev/maven-releases/
+
- com.github.steveice10
- mcprotocollib
- 1.20-1-SNAPSHOT
+ org.geysermc.mcprotocollib
+ protocol
+ 1.21-SNAPSHOT
@@ -48,7 +56,7 @@
com.mojang
brigadier
- 1.1.0-SNAPSHOT
+ 1.0.18
diff --git a/src/main/java/land/chipmunk/chipmunkbot/ChipmunkBot.java b/src/main/java/land/chipmunk/chipmunkbot/ChipmunkBot.java
index 9568d61..03867a5 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/ChipmunkBot.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/ChipmunkBot.java
@@ -1,8 +1,9 @@
package land.chipmunk.chipmunkbot;
-import com.github.steveice10.mc.protocol.MinecraftProtocol;
import lombok.Getter;
import land.chipmunk.chipmunkbot.plugins.*;
+import org.geysermc.mcprotocollib.protocol.MinecraftProtocol;
+
import java.util.List;
public class ChipmunkBot extends Client {
diff --git a/src/main/java/land/chipmunk/chipmunkbot/Client.java b/src/main/java/land/chipmunk/chipmunkbot/Client.java
index ed871bc..5d86a01 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/Client.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/Client.java
@@ -1,13 +1,14 @@
package land.chipmunk.chipmunkbot;
-import com.github.steveice10.mc.protocol.MinecraftProtocol;
-import com.github.steveice10.packetlib.ProxyInfo;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.tcp.TcpClientSession;
-import com.github.steveice10.packetlib.packet.Packet;
-import com.github.steveice10.packetlib.event.session.*;
-import com.github.steveice10.mc.auth.data.GameProfile;
-import com.github.steveice10.mc.protocol.packet.login.clientbound.ClientboundGameProfilePacket;
+import land.chipmunk.chipmunkbot.util.ComponentUtilities;
+import org.geysermc.mcprotocollib.auth.GameProfile;
+import org.geysermc.mcprotocollib.network.ProxyInfo;
+import org.geysermc.mcprotocollib.protocol.MinecraftProtocol;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.tcp.TcpClientSession;
+import org.geysermc.mcprotocollib.network.packet.Packet;
+import org.geysermc.mcprotocollib.network.event.session.*;
+import org.geysermc.mcprotocollib.protocol.packet.login.clientbound.ClientboundGameProfilePacket;
import java.util.Timer;
import java.util.TimerTask;
import java.util.List;
diff --git a/src/main/java/land/chipmunk/chipmunkbot/command/PlayerCommandSource.java b/src/main/java/land/chipmunk/chipmunkbot/command/PlayerCommandSource.java
index 9600632..78f8d66 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/command/PlayerCommandSource.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/command/PlayerCommandSource.java
@@ -3,7 +3,6 @@ package land.chipmunk.chipmunkbot.command;
import land.chipmunk.chipmunkbot.data.MutablePlayerListEntry;
import land.chipmunk.chipmunkbot.util.UUIDUtilities;
import land.chipmunk.chipmunkbot.ChipmunkBot;
-import com.github.steveice10.mc.auth.data.GameProfile;
import net.kyori.adventure.text.Component;
import net.kyori.adventure.text.format.NamedTextColor;
import net.kyori.adventure.text.format.TextColor;
@@ -12,6 +11,8 @@ import net.kyori.adventure.text.format.Style;
import net.kyori.adventure.text.event.ClickEvent;
import net.kyori.adventure.text.event.HoverEvent;
import net.kyori.adventure.key.Key;
+import org.geysermc.mcprotocollib.auth.GameProfile;
+
import java.util.UUID;
public class PlayerCommandSource extends CommandSource {
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/EchoCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/EchoCommand.java
index 28173b6..c3043a2 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/EchoCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/EchoCommand.java
@@ -16,7 +16,6 @@ public class EchoCommand {
dispatcher.register(
literal("echo")
- .describe(ComponentMessage.wrap(Component.text("Echoes a message")))
.then(
argument("text", greedyString())
.executes(instance::echo)
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/HelpCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/HelpCommand.java
index 2d01e61..c1ff758 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/HelpCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/HelpCommand.java
@@ -27,7 +27,6 @@ public class HelpCommand {
dispatcher.register(
literal("help")
- .describe(ComponentMessage.wrap(Component.text("Shows the help")))
.executes(instance::sendCommandList)
.then(
argument("command", greedyString())
@@ -106,13 +105,10 @@ public class HelpCommand {
);
}
- final Message description = node.getDescription();
-
components.add(
Component.translatable(
- "%s - %s",
- Component.text(node.getName()).color(TextColor.fromHexString(config.color().primary())),
- Component.text(description == null ? "No description" : description.getString()).color(NamedTextColor.GRAY)
+ "%s",
+ Component.text(node.getName()).color(TextColor.fromHexString(config.color().primary()))
).color(NamedTextColor.DARK_GRAY)
);
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/InfoCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/InfoCommand.java
index cff6f14..51449f2 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/InfoCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/InfoCommand.java
@@ -28,7 +28,6 @@ public class InfoCommand {
dispatcher.register(
literal("info")
- .describe(ComponentMessage.wrap(Component.text("Shows the info about the bot")))
.executes(instance::sendBotInfo)
.then(
literal("server")
@@ -42,7 +41,7 @@ public class InfoCommand {
client = source.client();
final Component component = Component.empty()
- .append(Component.text("Chipmunk(Sex)Bot", TextColor.fromHexString(client.config().color().primary())))
+ .append(Component.text("ChipmunkBot", TextColor.fromHexString(client.config().color().primary())))
.append(Component.text(" - A utility bot for free-operator servers with minimal or no restrictions", NamedTextColor.GRAY))
.append(Component.newline())
.append(Component.text("Made by ", NamedTextColor.GRAY))
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/LogQueryCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/LogQueryCommand.java
index 2ac3b95..ecf96dd 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/LogQueryCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/LogQueryCommand.java
@@ -38,7 +38,6 @@ public class LogQueryCommand {
dispatcher.register(
literal("logquery")
- .describe(ComponentMessage.wrap(Component.text("Queries the bots log files")))
.then(
literal("abort")
.executes(instance::abortCommand)
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/MusicCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/MusicCommand.java
index 9ae70e2..7cbd462 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/MusicCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/MusicCommand.java
@@ -43,7 +43,6 @@ public class MusicCommand {
dispatcher.register(
literal("music")
- .describe(ComponentMessage.wrap(Component.text("Play musics")))
.then(
literal("play")
.then(
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/NetMsgCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/NetMsgCommand.java
index c7b5a9a..9fd742b 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/NetMsgCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/NetMsgCommand.java
@@ -9,9 +9,9 @@ import static com.mojang.brigadier.arguments.StringArgumentType.greedyString;
import static com.mojang.brigadier.arguments.StringArgumentType.getString;
import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.context.CommandContext;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.mc.protocol.MinecraftProtocol;
-import com.github.steveice10.mc.protocol.data.ProtocolState;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.protocol.MinecraftProtocol;
+import org.geysermc.mcprotocollib.protocol.data.ProtocolState;
import net.kyori.adventure.text.Component;
import net.kyori.adventure.text.format.NamedTextColor;
import net.kyori.adventure.text.format.TextColor;
@@ -22,7 +22,6 @@ public class NetMsgCommand {
dispatcher.register(
literal("netmsg")
- .describe(ComponentMessage.wrap(Component.text("Broadcasts a message to every server")))
.then(
argument("message", greedyString())
.executes(instance::netmsg)
@@ -47,7 +46,7 @@ public class NetMsgCommand {
final Session session = remote.session();
final MinecraftProtocol protocol = (MinecraftProtocol) session.getPacketProtocol();
- if (!session.isConnected() || protocol.getState() != ProtocolState.GAME) continue;
+ if (!session.isConnected() || protocol.getOutboundState() != ProtocolState.GAME) continue;
((ChipmunkBot) remote).chat().tellraw(message);
}
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/ReconnectCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/ReconnectCommand.java
index e5bf34a..d3fdab1 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/ReconnectCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/ReconnectCommand.java
@@ -13,7 +13,6 @@ public class ReconnectCommand {
dispatcher.register(
literal("reconnect")
- .describe(ComponentMessage.wrap(Component.text("Reconnects the bot")))
.executes(instance::reconnect)
);
}
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/RunCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/RunCommand.java
index 1708737..edcfd21 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/RunCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/RunCommand.java
@@ -10,8 +10,8 @@ import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.context.CommandContext;
import net.kyori.adventure.text.Component;
import net.kyori.adventure.text.serializer.gson.GsonComponentSerializer;
-import com.github.steveice10.opennbt.tag.builtin.CompoundTag;
-import com.github.steveice10.opennbt.tag.builtin.StringTag;
+import org.cloudburstmc.nbt.NbtMap;
+
import java.util.concurrent.CompletableFuture;
public class RunCommand {
@@ -20,7 +20,6 @@ public class RunCommand {
dispatcher.register(
literal("run")
- .describe(ComponentMessage.wrap(Component.text("Runs a command in the command core and return its output")))
.then(
argument("command", greedyString())
.executes(instance::run)
@@ -32,11 +31,11 @@ public class RunCommand {
final CommandSource source = context.getSource();
final ChipmunkBot client = source.client();
- final CompletableFuture future = client.core().runTracked(getString(context, "command"));
+ final CompletableFuture future = client.core().runTracked(getString(context, "command"));
future.thenApply(tag -> {
- if (!tag.contains("LastOutput") || !(tag.get("LastOutput") instanceof StringTag)) return tag;
- final String outputJson = ((StringTag) tag.get("LastOutput")).getValue();
+ if (!tag.containsKey("LastOutput") || !(tag.get("LastOutput") instanceof String)) return tag;
+ final String outputJson = tag.getString("LastOutput");
try {
final Component output = GsonComponentSerializer.gson().deserialize(outputJson);
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/SayCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/SayCommand.java
index c6fee57..412c888 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/SayCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/SayCommand.java
@@ -18,7 +18,6 @@ public class SayCommand {
dispatcher.register(
literal("say")
- .describe(ComponentMessage.wrap(Component.text("Makes the bot say a message")))
.then(
argument("message", greedyString())
.executes(instance::say)
diff --git a/src/main/java/land/chipmunk/chipmunkbot/commands/TestCommand.java b/src/main/java/land/chipmunk/chipmunkbot/commands/TestCommand.java
index 6a41a2c..1b8664c 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/commands/TestCommand.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/commands/TestCommand.java
@@ -12,7 +12,6 @@ public class TestCommand {
dispatcher.register(
literal("test")
- .describe(ComponentMessage.wrap(Component.text("Tests if the bot is online/working")))
.executes(instance::helloWorld)
);
}
diff --git a/src/main/java/land/chipmunk/chipmunkbot/data/MutablePlayerListEntry.java b/src/main/java/land/chipmunk/chipmunkbot/data/MutablePlayerListEntry.java
index 1f8f602..62b1745 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/data/MutablePlayerListEntry.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/data/MutablePlayerListEntry.java
@@ -1,8 +1,8 @@
package land.chipmunk.chipmunkbot.data;
-import com.github.steveice10.mc.auth.data.GameProfile;
-import com.github.steveice10.mc.protocol.data.game.PlayerListEntry;
-import com.github.steveice10.mc.protocol.data.game.entity.player.GameMode;
+import org.geysermc.mcprotocollib.auth.GameProfile;
+import org.geysermc.mcprotocollib.protocol.data.game.PlayerListEntry;
+import org.geysermc.mcprotocollib.protocol.data.game.entity.player.GameMode;
import net.kyori.adventure.text.Component;
import lombok.Data;
import lombok.AllArgsConstructor;
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/ChatPlugin.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/ChatPlugin.java
index 56a49bc..e23d012 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/ChatPlugin.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/ChatPlugin.java
@@ -5,28 +5,28 @@ import land.chipmunk.chipmunkbot.data.chat.PlayerMessage;
import land.chipmunk.chipmunkbot.data.chat.SystemChatParser;
import land.chipmunk.chipmunkbot.data.MutablePlayerListEntry;
import land.chipmunk.chipmunkbot.util.UUIDUtilities;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.ClientboundSystemChatPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.ClientboundPlayerChatPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.ClientboundDisguisedChatPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.ServerboundChatPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.ServerboundChatCommandPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.inventory.ServerboundSetCreativeModeSlotPacket;
-import com.github.steveice10.packetlib.packet.Packet;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.mc.protocol.data.game.entity.metadata.ItemStack;
-import com.github.steveice10.opennbt.tag.builtin.CompoundTag;
-import com.github.steveice10.opennbt.tag.builtin.StringTag;
+import org.cloudburstmc.nbt.NbtMap;
+import org.cloudburstmc.nbt.NbtMapBuilder;
+import org.geysermc.mcprotocollib.protocol.data.game.item.ItemStack;
+import org.geysermc.mcprotocollib.protocol.data.game.item.component.DataComponent;
+import org.geysermc.mcprotocollib.protocol.data.game.item.component.DataComponentType;
+import org.geysermc.mcprotocollib.protocol.data.game.item.component.DataComponents;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.ClientboundSystemChatPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.ClientboundPlayerChatPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.ClientboundDisguisedChatPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.ServerboundChatPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.ServerboundChatCommandPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.inventory.ServerboundSetCreativeModeSlotPacket;
+import org.geysermc.mcprotocollib.network.packet.Packet;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
import net.kyori.adventure.text.Component;
import net.kyori.adventure.text.TextComponent;
import net.kyori.adventure.text.serializer.gson.GsonComponentSerializer;
import lombok.Getter;
-import java.util.BitSet;
-import java.util.Collections;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.UUID;
+
+import java.util.*;
import java.time.Instant;
import java.nio.charset.StandardCharsets;
@@ -58,7 +58,7 @@ public class ChatPlugin extends SessionAdapter {
public void command (String command) {
if (command.length() > 256) return;
- final ServerboundChatCommandPacket packet = new ServerboundChatCommandPacket(command, Instant.now().toEpochMilli(), 0, Collections.emptyList(), 0, new BitSet());
+ final ServerboundChatCommandPacket packet = new ServerboundChatCommandPacket(command);
client.session().send(packet);
}
@@ -147,12 +147,19 @@ public class ChatPlugin extends SessionAdapter {
if (tagString.getBytes(StandardCharsets.UTF_8).length > 65535) return;
- CompoundTag itemTag = new CompoundTag("");
- itemTag.put(new StringTag("m", tagString));
+ final NbtMapBuilder blockEntityTagBuilder = NbtMap.builder();
+
+ final NbtMap itemTag = blockEntityTagBuilder.putString("m", tagString).build();
+
+ final Map, DataComponent, ?>> map = new HashMap<>();
+
+ map.put(DataComponentType.BLOCK_ENTITY_DATA, DataComponentType.BLOCK_ENTITY_DATA.getDataComponentFactory().create(DataComponentType.BLOCK_ENTITY_DATA, itemTag));
+
+ final DataComponents dataComponents = new DataComponents(map);
final Session session = client.session();
- session.send(new ServerboundSetCreativeModeSlotPacket(26, new ItemStack(1 /* stone */, 1, itemTag)));
+ session.send(new ServerboundSetCreativeModeSlotPacket((short) 26, new ItemStack(1 /* stone */, 1, dataComponents)));
client.core().run("minecraft:tellraw " + targets + " {\"nbt\":\"Inventory[0].tag.m\",\"entity\":\"" + client.profile().getIdAsString() + "\",\"interpret\":" + interpret + "}"); // TODO: Use GSON instead of concatenating strings, and hardcode less of this (it shouldn't matter here but yes)
return;
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/CommandCore.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/CommandCore.java
index c3b6b11..99a0a69 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/CommandCore.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/CommandCore.java
@@ -4,30 +4,30 @@ import land.chipmunk.chipmunkbot.ChipmunkBot;
import land.chipmunk.chipmunkbot.Configuration;
import land.chipmunk.chipmunkbot.data.BlockArea;
import org.cloudburstmc.math.vector.Vector3i;
-import com.github.steveice10.packetlib.packet.Packet;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.packetlib.event.session.DisconnectedEvent;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.entity.player.ClientboundPlayerPositionPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.player.ServerboundUseItemOnPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.inventory.ServerboundSetCreativeModeSlotPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.player.ServerboundPlayerActionPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.inventory.ServerboundSetCommandBlockPacket;
-import com.github.steveice10.mc.protocol.data.game.entity.metadata.ItemStack;
-import com.github.steveice10.mc.protocol.data.game.entity.player.Hand;
-import com.github.steveice10.mc.protocol.data.game.entity.object.Direction;
-import com.github.steveice10.mc.protocol.data.game.entity.player.PlayerAction;
-import com.github.steveice10.mc.protocol.data.game.level.block.CommandBlockMode;
-import com.github.steveice10.opennbt.tag.builtin.CompoundTag;
-import com.github.steveice10.opennbt.tag.builtin.StringTag;
-import com.github.steveice10.opennbt.tag.builtin.ByteTag;
+import org.cloudburstmc.nbt.NbtMap;
+import org.cloudburstmc.nbt.NbtMapBuilder;
+import org.geysermc.mcprotocollib.network.packet.Packet;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.network.event.session.DisconnectedEvent;
+import org.geysermc.mcprotocollib.protocol.data.game.item.ItemStack;
+import org.geysermc.mcprotocollib.protocol.data.game.item.component.DataComponent;
+import org.geysermc.mcprotocollib.protocol.data.game.item.component.DataComponentType;
+import org.geysermc.mcprotocollib.protocol.data.game.item.component.DataComponents;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.entity.player.ClientboundPlayerPositionPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.player.ServerboundUseItemOnPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.inventory.ServerboundSetCreativeModeSlotPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.player.ServerboundPlayerActionPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.inventory.ServerboundSetCommandBlockPacket;
+import org.geysermc.mcprotocollib.protocol.data.game.entity.player.Hand;
+import org.geysermc.mcprotocollib.protocol.data.game.entity.object.Direction;
+import org.geysermc.mcprotocollib.protocol.data.game.entity.player.PlayerAction;
+import org.geysermc.mcprotocollib.protocol.data.game.level.block.CommandBlockMode;
import lombok.Getter;
import lombok.Setter;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Timer;
-import java.util.TimerTask;
+
+import java.util.*;
import java.util.concurrent.CompletableFuture;
public class CommandCore extends SessionAdapter {
@@ -95,11 +95,19 @@ public class CommandCore extends SessionAdapter {
relEnd.getZ() + origin.getZ()
);
- CompoundTag itemTag = new CompoundTag("");
- CompoundTag blockEntityTag = new CompoundTag("BlockEntityTag");
- blockEntityTag.put(new StringTag("Command", command));
- blockEntityTag.put(new ByteTag("auto", (byte) 1));
- itemTag.put(blockEntityTag);
+ final NbtMapBuilder blockEntityTagBuilder = NbtMap.builder();
+
+ blockEntityTagBuilder.putString("id", "minecraft:command_block");
+ blockEntityTagBuilder.putString("Command", command);
+ blockEntityTagBuilder.putByte("auto", (byte) 1);
+
+ final NbtMap blockEntityTag = blockEntityTagBuilder.build();
+
+ final Map, DataComponent, ?>> map = new HashMap<>();
+
+ map.put(DataComponentType.BLOCK_ENTITY_DATA, DataComponentType.BLOCK_ENTITY_DATA.getDataComponentFactory().create(DataComponentType.BLOCK_ENTITY_DATA, blockEntityTag));
+
+ final DataComponents dataComponents = new DataComponents(map);
final PositionManager position = client.position();
@@ -108,7 +116,7 @@ public class CommandCore extends SessionAdapter {
// client.chat().command(command);
final Session session = client.session();
- session.send(new ServerboundSetCreativeModeSlotPacket(45, new ItemStack(373 /* command_block */, 1, itemTag)));
+ session.send(new ServerboundSetCreativeModeSlotPacket((short) 45, new ItemStack(395 /* command_block */, 1, dataComponents)));
session.send(new ServerboundPlayerActionPacket(PlayerAction.START_DIGGING, temporaryBlockPosition, Direction.NORTH, 0));
session.send(new ServerboundUseItemOnPacket(temporaryBlockPosition, Direction.NORTH, Hand.OFF_HAND, 0.5f, 0.5f, 0.5f, false, 0));
}
@@ -169,13 +177,13 @@ public class CommandCore extends SessionAdapter {
incrementCurrentBlock();
}
- public CompletableFuture runTracked (String command) {
- if (command.length() > maxCommandLength()) return emptyCompoundTagFuture();
+ public CompletableFuture runTracked (String command) {
+ if (command.length() > maxCommandLength()) return emptyNbtMapFuture();
if (!enabled) {
client.chat().command(command); // fall back to chat
- return emptyCompoundTagFuture();
+ return emptyNbtMapFuture();
}
final Session session = client.session();
@@ -187,7 +195,7 @@ public class CommandCore extends SessionAdapter {
incrementCurrentBlock();
- CompletableFuture future = new CompletableFuture();
+ CompletableFuture future = new CompletableFuture();
final Timer timer = new Timer();
final TimerTask queryTask = new TimerTask() {
@@ -204,9 +212,9 @@ public class CommandCore extends SessionAdapter {
return future;
}
- private CompletableFuture emptyCompoundTagFuture () {
- CompletableFuture future = new CompletableFuture();
- future.complete(new CompoundTag(""));
+ private CompletableFuture emptyNbtMapFuture () {
+ CompletableFuture future = new CompletableFuture();
+ future.complete(NbtMap.EMPTY);
return future;
}
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/CommandSpyPlugin.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/CommandSpyPlugin.java
index 0e97f9c..f68355a 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/CommandSpyPlugin.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/CommandSpyPlugin.java
@@ -19,8 +19,16 @@ public class CommandSpyPlugin extends ChatPlugin.Listener {
private static final Style ENABLED_STYLE = Style.style(NamedTextColor.YELLOW);
private static final Style DISABLED_STYLE = Style.style(NamedTextColor.AQUA);
- private static final Component COMMANDSPY_ENABLED_COMPONENT = Component.text("Successfully enabled CommandSpy");
- private static final Component COMMANDSPY_DISABLED_COMPONENT = Component.text("Successfully disabled CommandSpy");
+ private static final Component COMMANDSPY_ENABLED_COMPONENT = Component
+ .empty()
+ .append(Component.text("Successfully "))
+ .append(Component.text("enabled"))
+ .append(Component.text(" CommandSpy"));
+ private static final Component COMMANDSPY_DISABLED_COMPONENT = Component
+ .empty()
+ .append(Component.text("Successfully "))
+ .append(Component.text("disabled"))
+ .append(Component.text(" CommandSpy"));
private static final Component COMMAND_SEPARATOR_COMPONENT = Component.text(": ");
private static final Component SIGN_CREATED_TEXT_COMPONENT = Component.text(" created a sign with contents:");
private static final Component SIGN_LINE_SEPARATOR_COMPONENT = Component.text("\n ");
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/PlayerListPlugin.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/PlayerListPlugin.java
index 33b6279..2a893e9 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/PlayerListPlugin.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/PlayerListPlugin.java
@@ -1,14 +1,14 @@
package land.chipmunk.chipmunkbot.plugins;
import land.chipmunk.chipmunkbot.ChipmunkBot;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.ClientboundPlayerInfoUpdatePacket;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.ClientboundPlayerInfoRemovePacket;
-import com.github.steveice10.packetlib.packet.Packet;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.mc.protocol.data.game.PlayerListEntry;
-import com.github.steveice10.mc.protocol.data.game.PlayerListEntryAction;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.ClientboundPlayerInfoUpdatePacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.ClientboundPlayerInfoRemovePacket;
+import org.geysermc.mcprotocollib.network.packet.Packet;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
+import org.geysermc.mcprotocollib.protocol.data.game.PlayerListEntry;
+import org.geysermc.mcprotocollib.protocol.data.game.PlayerListEntryAction;
import net.kyori.adventure.text.Component;
import land.chipmunk.chipmunkbot.data.MutablePlayerListEntry;
@@ -81,7 +81,7 @@ public class PlayerListPlugin extends SessionAdapter {
}
private final MutablePlayerListEntry getEntry (PlayerListEntry other) {
- return getEntry(other.getProfile().getId());
+ return getEntry(other.getProfileId());
}
private void addPlayer (PlayerListEntry newEntry) {
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/PositionManager.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/PositionManager.java
index 73852cb..2931e10 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/PositionManager.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/PositionManager.java
@@ -2,12 +2,12 @@ package land.chipmunk.chipmunkbot.plugins;
import land.chipmunk.chipmunkbot.Client;
import org.cloudburstmc.math.vector.Vector3d;
-import com.github.steveice10.packetlib.packet.Packet;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.entity.player.ClientboundPlayerPositionPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.level.ServerboundAcceptTeleportationPacket;
+import org.geysermc.mcprotocollib.network.packet.Packet;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.entity.player.ClientboundPlayerPositionPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.level.ServerboundAcceptTeleportationPacket;
import org.cloudburstmc.math.vector.Vector3d;
import org.cloudburstmc.math.vector.Vector3i;
import lombok.Getter;
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/QueryPlugin.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/QueryPlugin.java
index 796c793..f3484ea 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/QueryPlugin.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/QueryPlugin.java
@@ -2,14 +2,14 @@ package land.chipmunk.chipmunkbot.plugins;
import land.chipmunk.chipmunkbot.Client;
import org.cloudburstmc.math.vector.Vector3i;
-import com.github.steveice10.packetlib.packet.Packet;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.level.ServerboundBlockEntityTagQuery;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.level.ServerboundEntityTagQuery;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.level.ClientboundTagQueryPacket;
-import com.github.steveice10.opennbt.tag.builtin.CompoundTag;
+import org.cloudburstmc.nbt.NbtMap;
+import org.geysermc.mcprotocollib.network.packet.Packet;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.level.ServerboundBlockEntityTagQueryPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.level.ServerboundEntityTagQuery;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.level.ClientboundTagQueryPacket;
import java.util.concurrent.CompletableFuture;
import java.util.Map;
import java.util.HashMap;
@@ -17,29 +17,29 @@ import java.util.HashMap;
public class QueryPlugin extends SessionAdapter {
private Client client;
private int nextTransactionId = 0;
- private Map> transactions = new HashMap<>();
+ private Map> transactions = new HashMap<>();
public QueryPlugin (Client client) {
this.client = client;
client.addListener((SessionListener) this);
}
- public CompletableFuture block (Vector3i position) {
+ public CompletableFuture block (Vector3i position) {
final int transactionId = nextTransactionId++;
if (nextTransactionId > Integer.MAX_VALUE) nextTransactionId = 0; // ? Can and should I use negative numbers too?
- client.session().send(new ServerboundBlockEntityTagQuery(transactionId, position));
+ client.session().send(new ServerboundBlockEntityTagQueryPacket(transactionId, position));
- final CompletableFuture future = new CompletableFuture();
+ final CompletableFuture future = new CompletableFuture();
transactions.put(transactionId, future);
return future;
}
- public CompletableFuture entity (int entityId) {
+ public CompletableFuture entity (int entityId) {
final int transactionId = nextTransactionId++;
if (nextTransactionId > Integer.MAX_VALUE) nextTransactionId = 0; // ? Can and should I use negative numbers too?
client.session().send(new ServerboundEntityTagQuery(transactionId, entityId));
- final CompletableFuture future = new CompletableFuture();
+ final CompletableFuture future = new CompletableFuture();
transactions.put(transactionId, future);
return future;
}
@@ -50,7 +50,7 @@ public class QueryPlugin extends SessionAdapter {
}
public void packetReceived (Session session, ClientboundTagQueryPacket packet) {
- final CompletableFuture future = transactions.get(packet.getTransactionId());
+ final CompletableFuture future = transactions.get(packet.getTransactionId());
if (future == null) return;
future.complete(packet.getNbt());
transactions.remove(future);
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/SelfCarePlugin.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/SelfCarePlugin.java
index acfe376..fd89ce7 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/SelfCarePlugin.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/SelfCarePlugin.java
@@ -1,23 +1,23 @@
package land.chipmunk.chipmunkbot.plugins;
import land.chipmunk.chipmunkbot.ChipmunkBot;
-import com.github.steveice10.packetlib.packet.Packet;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.packet.PacketProtocol;
-import com.github.steveice10.mc.protocol.MinecraftProtocol;
-import com.github.steveice10.mc.protocol.data.game.entity.player.GameMode;
-import com.github.steveice10.mc.protocol.data.ProtocolState;
-import com.github.steveice10.mc.protocol.data.game.level.notify.GameEvent;
-import com.github.steveice10.mc.protocol.data.game.level.notify.GameEventValue;
-import com.github.steveice10.mc.protocol.data.game.entity.EntityEvent;
-import com.github.steveice10.mc.protocol.data.game.ClientCommand;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.packetlib.event.session.DisconnectedEvent;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.ClientboundLoginPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.level.ClientboundGameEventPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.entity.ClientboundEntityEventPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.ServerboundClientCommandPacket;
+import org.geysermc.mcprotocollib.network.packet.Packet;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.packet.PacketProtocol;
+import org.geysermc.mcprotocollib.protocol.MinecraftProtocol;
+import org.geysermc.mcprotocollib.protocol.data.game.entity.player.GameMode;
+import org.geysermc.mcprotocollib.protocol.data.ProtocolState;
+import org.geysermc.mcprotocollib.protocol.data.game.level.notify.GameEvent;
+import org.geysermc.mcprotocollib.protocol.data.game.level.notify.GameEventValue;
+import org.geysermc.mcprotocollib.protocol.data.game.entity.EntityEvent;
+import org.geysermc.mcprotocollib.protocol.data.game.ClientCommand;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
+import org.geysermc.mcprotocollib.network.event.session.DisconnectedEvent;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.ClientboundLoginPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.level.ClientboundGameEventPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.entity.ClientboundEntityEventPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.ServerboundClientCommandPacket;
import land.chipmunk.chipmunkbot.Configuration;
import land.chipmunk.chipmunkbot.util.ComponentUtilities;
import lombok.Getter;
@@ -62,7 +62,7 @@ public class SelfCarePlugin extends SessionAdapter {
public void run () {
final Session session = client.session();
final PacketProtocol protocol = session.getPacketProtocol();
- if (!session.isConnected() || (protocol instanceof MinecraftProtocol && ((MinecraftProtocol) protocol).getState() != ProtocolState.GAME)) return;
+ if (!session.isConnected() || (protocol instanceof MinecraftProtocol && ((MinecraftProtocol) protocol).getOutboundState() != ProtocolState.GAME)) return;
// TODO: Maybe make it possible for other stuff to listen for ticks
tick();
@@ -97,7 +97,7 @@ public class SelfCarePlugin extends SessionAdapter {
public void packetReceived (Session session, ClientboundLoginPacket packet) {
entityId = packet.getEntityId(); // TODO: Move entity id handling somewhere else
- gamemode = packet.getGameMode();
+ gamemode = packet.getCommonPlayerSpawnInfo().getGameMode();
}
public void packetReceived (Session session, ClientboundEntityEventPacket packet) {
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/SongPlayer.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/SongPlayer.java
index b198307..1d6b76e 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/SongPlayer.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/SongPlayer.java
@@ -2,11 +2,11 @@ package land.chipmunk.chipmunkbot.plugins;
import land.chipmunk.chipmunkbot.ChipmunkBot;
import land.chipmunk.chipmunkbot.song.*;
-// import com.github.steveice10.packetlib.packet.Packet;
-// import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.packetlib.event.session.DisconnectedEvent;
+// import org.geysermc.mcprotocollib.network.packet.Packet;
+// import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.network.event.session.DisconnectedEvent;
import land.chipmunk.chipmunkbot.util.MathUtilities;
import net.kyori.adventure.text.Component;
import net.kyori.adventure.text.format.NamedTextColor;
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/TabCompletePlugin.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/TabCompletePlugin.java
index 64b3430..20ed8c8 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/TabCompletePlugin.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/TabCompletePlugin.java
@@ -2,12 +2,12 @@ package land.chipmunk.chipmunkbot.plugins;
import land.chipmunk.chipmunkbot.Client;
import org.cloudburstmc.math.vector.Vector3i;
-import com.github.steveice10.packetlib.packet.Packet;
-import com.github.steveice10.packetlib.Session;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.mc.protocol.packet.ingame.serverbound.ServerboundCommandSuggestionPacket;
-import com.github.steveice10.mc.protocol.packet.ingame.clientbound.ClientboundCommandSuggestionsPacket;
+import org.geysermc.mcprotocollib.network.packet.Packet;
+import org.geysermc.mcprotocollib.network.Session;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.serverbound.ServerboundCommandSuggestionPacket;
+import org.geysermc.mcprotocollib.protocol.packet.ingame.clientbound.ClientboundCommandSuggestionsPacket;
import java.util.concurrent.CompletableFuture;
import java.util.Map;
import java.util.HashMap;
diff --git a/src/main/java/land/chipmunk/chipmunkbot/plugins/TickLoop.java b/src/main/java/land/chipmunk/chipmunkbot/plugins/TickLoop.java
index b1647fe..0f7c5b5 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/plugins/TickLoop.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/plugins/TickLoop.java
@@ -1,11 +1,11 @@
package land.chipmunk.chipmunkbot.plugins;
import land.chipmunk.chipmunkbot.Client;
-import com.github.steveice10.packetlib.event.session.SessionListener;
-import com.github.steveice10.packetlib.event.session.SessionAdapter;
-import com.github.steveice10.packetlib.event.session.DisconnectedEvent;
-import com.github.steveice10.mc.protocol.MinecraftProtocol;
-import com.github.steveice10.mc.protocol.data.ProtocolState;
+import org.geysermc.mcprotocollib.network.event.session.SessionListener;
+import org.geysermc.mcprotocollib.network.event.session.SessionAdapter;
+import org.geysermc.mcprotocollib.network.event.session.DisconnectedEvent;
+import org.geysermc.mcprotocollib.protocol.MinecraftProtocol;
+import org.geysermc.mcprotocollib.protocol.data.ProtocolState;
import lombok.Getter;
import java.util.ArrayList;
import java.util.List;
@@ -26,7 +26,7 @@ public class TickLoop extends SessionAdapter {
public void run () {
for (Listener listener : listeners) {
listener.onTick(tick);
- if (((MinecraftProtocol) client.session().getPacketProtocol()).getState() == ProtocolState.GAME) listener.onGameTick(tick);
+ if (((MinecraftProtocol) client.session().getPacketProtocol()).getOutboundState() == ProtocolState.GAME) listener.onGameTick(tick);
}
}
};
diff --git a/src/main/java/land/chipmunk/chipmunkbot/systemChat/KaboomChatParser.java b/src/main/java/land/chipmunk/chipmunkbot/systemChat/KaboomChatParser.java
index c283e29..c9ea209 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/systemChat/KaboomChatParser.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/systemChat/KaboomChatParser.java
@@ -1,7 +1,6 @@
package land.chipmunk.chipmunkbot.systemChat;
-import com.github.steveice10.mc.auth.data.GameProfile;
-import com.github.steveice10.mc.protocol.data.game.entity.player.GameMode;
+import org.geysermc.mcprotocollib.protocol.data.game.entity.player.GameMode;
import land.chipmunk.chipmunkbot.ChipmunkBot;
import land.chipmunk.chipmunkbot.data.MutablePlayerListEntry;
import land.chipmunk.chipmunkbot.data.chat.PlayerMessage;
diff --git a/src/main/java/land/chipmunk/chipmunkbot/systemChat/MinecraftChatParser.java b/src/main/java/land/chipmunk/chipmunkbot/systemChat/MinecraftChatParser.java
index d8e2c97..6caa5eb 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/systemChat/MinecraftChatParser.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/systemChat/MinecraftChatParser.java
@@ -1,7 +1,7 @@
package land.chipmunk.chipmunkbot.systemChat;
-import com.github.steveice10.mc.auth.data.GameProfile;
-import com.github.steveice10.mc.protocol.data.game.entity.player.GameMode;
+import org.geysermc.mcprotocollib.auth.GameProfile;
+import org.geysermc.mcprotocollib.protocol.data.game.entity.player.GameMode;
import land.chipmunk.chipmunkbot.ChipmunkBot;
import land.chipmunk.chipmunkbot.data.MutablePlayerListEntry;
import land.chipmunk.chipmunkbot.data.chat.PlayerMessage;
diff --git a/src/main/java/land/chipmunk/chipmunkbot/util/UUIDUtilities.java b/src/main/java/land/chipmunk/chipmunkbot/util/UUIDUtilities.java
index 17a789c..60b4530 100644
--- a/src/main/java/land/chipmunk/chipmunkbot/util/UUIDUtilities.java
+++ b/src/main/java/land/chipmunk/chipmunkbot/util/UUIDUtilities.java
@@ -1,6 +1,5 @@
package land.chipmunk.chipmunkbot.util;
-import com.github.steveice10.opennbt.tag.builtin.IntArrayTag;
import java.util.UUID;
import java.nio.ByteBuffer;
@@ -19,9 +18,9 @@ public class UUIDUtilities {
return intArray;
}
- public static IntArrayTag tag (UUID uuid) {
- return new IntArrayTag("", intArray(uuid));
- }
+// public static IntArrayTag tag (UUID uuid) {
+// return new IntArrayTag("", intArray(uuid));
+// }
public static String snbt (UUID uuid) {
int[] array = intArray(uuid);