mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2025-08-28 16:22:18 +00:00
Update to 1.16.4
This commit is contained in:
parent
bcc0effd00
commit
e12ce95b2d
@ -55,8 +55,8 @@ dependencies {
|
||||
testImplementation 'org.junit.jupiter:junit-jupiter-params:5.7.0'
|
||||
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.7.0'
|
||||
|
||||
modRuntime "me.shedaniel:RoughlyEnoughItems-api:5.2.10"
|
||||
modRuntime "me.shedaniel:RoughlyEnoughItems:5.2.10"
|
||||
modRuntime "me.shedaniel:RoughlyEnoughItems-api:5.8.9"
|
||||
modRuntime "me.shedaniel:RoughlyEnoughItems:5.8.9"
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
|
@ -5,13 +5,13 @@ org.gradle.jvmargs=-Xmx1G
|
||||
mod_version=1.95.1-beta
|
||||
|
||||
# Minecraft properties
|
||||
mc_version=1.16.2
|
||||
mappings_version=31
|
||||
mc_version=1.16.4
|
||||
mappings_version=9
|
||||
|
||||
# Dependencies
|
||||
cloth_config_version=4.8.1
|
||||
fabric_api_version=0.19.0+build.398-1.16
|
||||
fabric_loader_version=0.9.2+build.206
|
||||
fabric_api_version=0.34.2+1.16
|
||||
fabric_loader_version=0.11.3
|
||||
jankson_version=1.2.0
|
||||
modmenu_version=1.14.6+
|
||||
cloth_api_version=1.4.5
|
||||
|
@ -590,4 +590,11 @@ c864576619751077a0d8ac1a18123e14b095ec03
|
||||
|
||||
Fix impostor recipes for disks
|
||||
```
|
||||
[TODO] [JUMT-03] REI still shows white disks, probably because it doesn' show nbt items.
|
||||
[TODO] [JUMT-03] REI still shows white disks, probably because it doesn' show nbt items.
|
||||
|
||||
```
|
||||
c5694ea9661c7a40021ebd280c378bd7bdc56988
|
||||
|
||||
Merge branch 'mc-1.15.x' into mc-1.16.x
|
||||
```
|
||||
Update to 1.16.4.
|
@ -48,7 +48,7 @@ import net.minecraft.util.Hand;
|
||||
import net.minecraft.util.collection.DefaultedList;
|
||||
import net.minecraft.util.math.ChunkPos;
|
||||
import net.minecraft.util.math.Vec3d;
|
||||
import net.minecraft.village.TraderOfferList;
|
||||
import net.minecraft.village.TradeOfferList;
|
||||
import net.minecraft.world.GameMode;
|
||||
|
||||
/**
|
||||
@ -105,7 +105,7 @@ public class FakePlayer extends ServerPlayerEntity {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void sendTradeOffers(int id, TraderOfferList list, int level, int experience, boolean levelled, boolean refreshable) { }
|
||||
public void sendTradeOffers(int id, TradeOfferList list, int level, int experience, boolean levelled, boolean refreshable) { }
|
||||
|
||||
@Override
|
||||
public void openHorseInventory(HorseBaseEntity horse, Inventory inventory) { }
|
||||
@ -251,10 +251,6 @@ public class FakePlayer extends ServerPlayerEntity {
|
||||
public void disconnect(Text message) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupEncryption(SecretKey key) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void disableAutoRead() {
|
||||
}
|
||||
|
@ -32,7 +32,7 @@ public class MixinWorld {
|
||||
|
||||
@Inject (method = "setBlockEntity", at = @At ("HEAD"))
|
||||
public void setBlockEntity(BlockPos pos, @Nullable BlockEntity entity, CallbackInfo info) {
|
||||
if (!World.isHeightInvalid(pos) && entity != null && !entity.isRemoved() && this.iteratingTickingBlockEntities) {
|
||||
if (!World.isOutOfBuildLimitVertically(pos) && entity != null && !entity.isRemoved() && this.iteratingTickingBlockEntities) {
|
||||
setWorld(entity, this);
|
||||
}
|
||||
}
|
||||
|
@ -31,7 +31,7 @@ public final class BundledRedstone {
|
||||
}
|
||||
|
||||
public static int getDefaultOutput(@Nonnull World world, @Nonnull BlockPos pos, @Nonnull Direction side) {
|
||||
return World.method_24794(pos) ? DefaultBundledRedstoneProvider.getDefaultBundledRedstoneOutput(world, pos, side) : -1;
|
||||
return World.isValid(pos) ? DefaultBundledRedstoneProvider.getDefaultBundledRedstoneOutput(world, pos, side) : -1;
|
||||
}
|
||||
|
||||
public static int getOutput(World world, BlockPos pos, Direction side) {
|
||||
@ -40,7 +40,7 @@ public final class BundledRedstone {
|
||||
}
|
||||
|
||||
private static int getUnmaskedOutput(World world, BlockPos pos, Direction side) {
|
||||
if (!World.method_24794(pos)) {
|
||||
if (!World.isValid(pos)) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
@ -35,13 +35,11 @@ public final class Peripherals {
|
||||
|
||||
@Nullable
|
||||
public static IPeripheral getPeripheral(World world, BlockPos pos, Direction side) {
|
||||
return World.method_24794(pos) && !world.isClient ? getPeripheralAt(world, pos, side) : null;
|
||||
return World.isValid(pos) && !world.isClient ? getPeripheralAt(world, pos, side) : null;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
private static IPeripheral getPeripheralAt(World world, BlockPos pos, Direction side) {
|
||||
BlockEntity block = world.getBlockEntity(pos);
|
||||
|
||||
// Try the handlers in order:
|
||||
for (IPeripheralProvider peripheralProvider : providers) {
|
||||
try {
|
||||
|
@ -17,7 +17,7 @@ import com.mojang.brigadier.suggestion.SuggestionsBuilder;
|
||||
import dan200.computercraft.api.turtle.FakePlayer;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.server.command.CommandSource;
|
||||
import net.minecraft.command.CommandSource;
|
||||
import net.minecraft.server.command.ServerCommandSource;
|
||||
import net.minecraft.server.network.ServerPlayerEntity;
|
||||
|
||||
|
@ -207,7 +207,7 @@ public class CommandAPI implements ILuaAPI {
|
||||
World world = this.computer.getWorld();
|
||||
BlockPos min = new BlockPos(Math.min(minX, maxX), Math.min(minY, maxY), Math.min(minZ, maxZ));
|
||||
BlockPos max = new BlockPos(Math.max(minX, maxX), Math.max(minY, maxY), Math.max(minZ, maxZ));
|
||||
if (!World.method_24794(min) || !World.method_24794(max)) {
|
||||
if (!World.isValid(min) || !World.isValid(max)) {
|
||||
throw new LuaException("Co-ordinates out of range");
|
||||
}
|
||||
|
||||
@ -284,7 +284,7 @@ public class CommandAPI implements ILuaAPI {
|
||||
// Get the details of the block
|
||||
World world = this.computer.getWorld();
|
||||
BlockPos position = new BlockPos(x, y, z);
|
||||
if (World.method_24794(position)) {
|
||||
if (World.isValid(position)) {
|
||||
return getBlockInfo(world, position);
|
||||
} else {
|
||||
throw new LuaException("Co-ordinates out of range");
|
||||
|
@ -316,7 +316,7 @@ public class ServerComputer extends ServerTerminal implements IComputer, IComput
|
||||
@Nonnull
|
||||
@Override
|
||||
public String getHostString() {
|
||||
return String.format("ComputerCraft %s (Minecraft %s)", ComputerCraftAPI.getInstalledVersion(), "1.16.2");
|
||||
return String.format("ComputerCraft %s (Minecraft %s)", ComputerCraftAPI.getInstalledVersion(), "1.16.4");
|
||||
}
|
||||
|
||||
@Nonnull
|
||||
|
@ -119,10 +119,10 @@ public class TurtleMoveCommand implements ITurtleCommand {
|
||||
}
|
||||
|
||||
private static TurtleCommandResult canEnter(TurtlePlayer turtlePlayer, World world, BlockPos position) {
|
||||
if (World.isHeightInvalid(position)) {
|
||||
if (World.isOutOfBuildLimitVertically(position)) {
|
||||
return TurtleCommandResult.failure(position.getY() < 0 ? "Too low to move" : "Too high to move");
|
||||
}
|
||||
if (!World.method_24794(position)) {
|
||||
if (!World.isValid(position)) {
|
||||
return TurtleCommandResult.failure("Cannot leave the world");
|
||||
}
|
||||
|
||||
|
@ -364,7 +364,7 @@ public class TurtlePlaceCommand implements ITurtleCommand {
|
||||
private static boolean canDeployOnBlock(@Nonnull ItemPlacementContext context, ITurtleAccess turtle, TurtlePlayer player, BlockPos position,
|
||||
Direction side, boolean allowReplaceable, String[] outErrorMessage) {
|
||||
World world = turtle.getWorld();
|
||||
if (!World.method_24794(position) || world.isAir(position) || (context.getStack()
|
||||
if (!World.isValid(position) || world.isAir(position) || (context.getStack()
|
||||
.getItem() instanceof BlockItem && WorldUtil.isLiquidBlock(world,
|
||||
position))) {
|
||||
return false;
|
||||
|
@ -77,7 +77,7 @@ public final class TurtlePlayer extends FakePlayer {
|
||||
private void setState(ITurtleAccess turtle) {
|
||||
if (this.currentScreenHandler != playerScreenHandler) {
|
||||
ComputerCraft.log.warn("Turtle has open container ({})", this.currentScreenHandler);
|
||||
closeCurrentScreen();
|
||||
closeHandledScreen();
|
||||
}
|
||||
|
||||
BlockPos position = turtle.getPosition();
|
||||
@ -91,13 +91,8 @@ public final class TurtlePlayer extends FakePlayer {
|
||||
}
|
||||
|
||||
public static TurtlePlayer get(ITurtleAccess access) {
|
||||
ServerWorld world = (ServerWorld) access.getWorld();
|
||||
if( !(access instanceof TurtleBrain) ) return create( access );
|
||||
|
||||
/*if (!(access instanceof TurtleBrain)) {
|
||||
return new TurtlePlayer(world, access.getOwningPlayer());
|
||||
}*/
|
||||
|
||||
TurtleBrain brain = (TurtleBrain) access;
|
||||
TurtlePlayer player = brain.m_cachedPlayer;
|
||||
if (player == null || player.getGameProfile() != getProfile(access.getOwningPlayer()) || player.getEntityWorld() != access.getWorld()) {
|
||||
|
@ -14,7 +14,6 @@ import dan200.computercraft.api.turtle.FakePlayer;
|
||||
import io.netty.channel.ChannelHandlerContext;
|
||||
import io.netty.util.concurrent.Future;
|
||||
import io.netty.util.concurrent.GenericFutureListener;
|
||||
|
||||
import net.minecraft.network.ClientConnection;
|
||||
import net.minecraft.network.NetworkSide;
|
||||
import net.minecraft.network.NetworkState;
|
||||
@ -25,15 +24,12 @@ import net.minecraft.network.packet.c2s.play.BoatPaddleStateC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.BookUpdateC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.ButtonClickC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.ChatMessageC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.ClickWindowC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.ClientCommandC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.ClientSettingsC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.ClientStatusC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.ConfirmGuiActionC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.CraftRequestC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.CreativeInventoryActionC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.CustomPayloadC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.GuiCloseC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.HandSwingC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.KeepAliveC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.PickFromInventoryC2SPacket;
|
||||
@ -48,7 +44,6 @@ import net.minecraft.network.packet.c2s.play.QueryEntityNbtC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.RenameItemC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.RequestCommandCompletionsC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.ResourcePackStatusC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.SelectVillagerTradeC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.SpectatorTeleportC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.TeleportConfirmC2SPacket;
|
||||
import net.minecraft.network.packet.c2s.play.UpdateBeaconC2SPacket;
|
||||
@ -127,10 +122,6 @@ public class FakeNetHandler extends ServerPlayNetworkHandler {
|
||||
public void onJigsawUpdate(@Nonnull UpdateJigsawC2SPacket packet) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onVillagerTradeSelect(@Nonnull SelectVillagerTradeC2SPacket packet) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBookUpdate(@Nonnull BookUpdateC2SPacket packet) {
|
||||
}
|
||||
@ -207,14 +198,6 @@ public class FakeNetHandler extends ServerPlayNetworkHandler {
|
||||
public void onClientStatus(@Nonnull ClientStatusC2SPacket packet) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onGuiClose(@Nonnull GuiCloseC2SPacket packet) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onClickWindow(@Nonnull ClickWindowC2SPacket packet) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCraftRequest(@Nonnull CraftRequestC2SPacket packet) {
|
||||
}
|
||||
@ -227,10 +210,6 @@ public class FakeNetHandler extends ServerPlayNetworkHandler {
|
||||
public void onCreativeInventoryAction(@Nonnull CreativeInventoryActionC2SPacket packet) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onConfirmTransaction(@Nonnull ConfirmGuiActionC2SPacket packet) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onSignUpdate(@Nonnull UpdateSignC2SPacket packet) {
|
||||
}
|
||||
@ -309,10 +288,6 @@ public class FakeNetHandler extends ServerPlayNetworkHandler {
|
||||
this.closeReason = message;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupEncryption(@Nonnull SecretKey key) {
|
||||
}
|
||||
|
||||
@Nonnull
|
||||
@Override
|
||||
public PacketListener getPacketListener() {
|
||||
|
@ -40,7 +40,7 @@ public final class WorldUtil {
|
||||
.makeMap();
|
||||
|
||||
public static boolean isLiquidBlock(World world, BlockPos pos) {
|
||||
if (!World.method_24794(pos)) {
|
||||
if (!World.isValid(pos)) {
|
||||
return false;
|
||||
}
|
||||
return world.getBlockState(pos)
|
||||
|
Loading…
x
Reference in New Issue
Block a user