Update to 1.19
This commit is contained in:
@@ -10,7 +10,6 @@ import net.minecraft.nbt.*;
|
||||
|
||||
import anticope.rejects.utils.GiveUtils;
|
||||
import meteordevelopment.meteorclient.systems.commands.Command;
|
||||
import net.minecraft.text.LiteralText;
|
||||
import net.minecraft.text.Text;
|
||||
import net.minecraft.util.registry.Registry;
|
||||
|
||||
@@ -73,7 +72,7 @@ public class GiveCommand extends Command {
|
||||
tag.putBoolean("Interpret", true);
|
||||
tag.putBoolean("NoGravity", true);
|
||||
tag.putBoolean("CustomNameVisible", true);
|
||||
tag.putString("CustomName", Text.Serializer.toJson(new LiteralText(message)));
|
||||
tag.putString("CustomName", Text.Serializer.toJson(Text.literal(message)));
|
||||
tag.put("Pos", NbtList);
|
||||
stack.setSubNbt("EntityTag", tag);
|
||||
GiveUtils.giveItem(stack);
|
||||
@@ -84,7 +83,7 @@ public class GiveCommand extends Command {
|
||||
String message = ctx.getArgument("message", String.class).replace("&", "\247");
|
||||
ItemStack stack = new ItemStack(Items.BAT_SPAWN_EGG);
|
||||
NbtCompound tag = new NbtCompound();
|
||||
tag.putString("CustomName", Text.Serializer.toJson(new LiteralText(message)));
|
||||
tag.putString("CustomName", Text.Serializer.toJson(Text.literal(message)));
|
||||
tag.putBoolean("NoAI", true);
|
||||
tag.putBoolean("Silent", true);
|
||||
tag.putBoolean("PersistenceRequired", true);
|
||||
|
||||
Reference in New Issue
Block a user