mirror of
https://github.com/architectury/architectury-api.git
synced 2026-03-28 03:56:59 -05:00
Update to 22w16b
This commit is contained in:
@@ -32,7 +32,6 @@ import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.nbt.Tag;
|
||||
import net.minecraft.network.FriendlyByteBuf;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.network.chat.TranslatableComponent;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import net.minecraft.world.level.BlockAndTintGetter;
|
||||
import net.minecraft.world.level.material.Fluid;
|
||||
@@ -48,7 +47,7 @@ public class FluidStackHooksImpl {
|
||||
return getNameClient(stack);
|
||||
}
|
||||
|
||||
return new TranslatableComponent(getTranslationKey(stack));
|
||||
return Component.translatable(getTranslationKey(stack));
|
||||
}
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
|
||||
@@ -22,7 +22,7 @@ package dev.architectury.impl.fabric;
|
||||
import dev.architectury.event.events.client.ClientScreenInputEvent;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.screens.Screen;
|
||||
import net.minecraft.network.chat.TextComponent;
|
||||
import net.minecraft.network.chat.Component;
|
||||
|
||||
public interface ScreenInputDelegate {
|
||||
Screen architectury_delegateInputs();
|
||||
@@ -31,7 +31,7 @@ public interface ScreenInputDelegate {
|
||||
private Screen parent;
|
||||
|
||||
public DelegateScreen(Screen parent) {
|
||||
super(TextComponent.EMPTY);
|
||||
super(Component.empty());
|
||||
this.parent = parent;
|
||||
}
|
||||
|
||||
|
||||
@@ -23,7 +23,6 @@ import dev.architectury.event.events.common.ChatEvent;
|
||||
import dev.architectury.impl.fabric.ChatComponentImpl;
|
||||
import net.minecraft.network.chat.ChatType;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.network.chat.TranslatableComponent;
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraft.server.level.ServerPlayer;
|
||||
import net.minecraft.server.network.ServerGamePacketListenerImpl;
|
||||
@@ -70,7 +69,7 @@ public abstract class MixinServerGamePacketListenerImpl {
|
||||
|
||||
this.chatSpamTickCount += 20;
|
||||
if (this.chatSpamTickCount > 200 && !this.server.getPlayerList().isOp(this.player.getGameProfile())) {
|
||||
this.disconnect(new TranslatableComponent("disconnect.spam"));
|
||||
this.disconnect(Component.translatable("disconnect.spam"));
|
||||
}
|
||||
ci.cancel();
|
||||
}
|
||||
|
||||
@@ -100,8 +100,10 @@ public class SpawnEntityPacket {
|
||||
}
|
||||
entity.setUUID(uuid);
|
||||
entity.setId(id);
|
||||
entity.setPacketCoordinates(x, y, z);
|
||||
entity.absMoveTo(x, y, z, xRot, yRot);
|
||||
entity.syncPacketPositionCodec(x, y, z);
|
||||
entity.moveTo(x, y, z);
|
||||
entity.setXRot(xRot);
|
||||
entity.setYRot(yRot);
|
||||
entity.setYHeadRot(yHeadRot);
|
||||
entity.setYBodyRot(yHeadRot);
|
||||
if (entity instanceof EntitySpawnExtension ext) {
|
||||
|
||||
Reference in New Issue
Block a user