This commit is contained in:
Chipmunk 2023-04-29 23:26:16 -04:00
parent c25d93968b
commit 3493df35e9
2 changed files with 2 additions and 2 deletions

View file

@ -109,7 +109,7 @@ public class ChatPlugin extends SessionAdapter {
public void tellraw (Component message, String targets) { public void tellraw (Component message, String targets) {
final int maxLength = client.core().maxCommandLength(); final int maxLength = client.core().maxCommandLength();
String command = "minecraft:tellraw " + targets + " " + GsonComponentSerializer.gson().serialize(message); String command = "minecraft:tellraw " + targets + " " + GsonComponentSerializer.gson().serialize(message);
if (command.length() > maxLength) command = "w " + targets + " " + ComponentUtilities.stringify(message); if (command.length() > maxLength) command = "minecraft:w " + targets + " " + ComponentUtilities.stringify(message);
client.core().run(command); client.core().run(command);
} }
public void tellraw (Component message) { tellraw(message, "@a"); } public void tellraw (Component message) { tellraw(message, "@a"); }

View file

@ -28,6 +28,6 @@ public class UUIDUtilities {
return "[I;" + array[0] + "," + array[1] + "," + array[2] + "," + array[3] + "]"; // TODO: improve lol return "[I;" + array[0] + "," + array[1] + "," + array[2] + "," + array[3] + "]"; // TODO: improve lol
} }
public static String selector (UUID uuid) { return "@a[limit=1,nbt={UUID:" + snbt(uuid) + "}]"; } public static String selector (UUID uuid) { return "@p[nbt={UUID:" + snbt(uuid) + "}]"; }
public static String exclusiveSelector (UUID uuid) { return "@a[nbt=!{UUID:" + snbt(uuid) + "}]"; } public static String exclusiveSelector (UUID uuid) { return "@a[nbt=!{UUID:" + snbt(uuid) + "}]"; }
} }