Skip to content

Commit

Permalink
1.20.2-pre2
Browse files Browse the repository at this point in the history
  • Loading branch information
modmuss50 committed Sep 7, 2023
1 parent 34a3e0e commit 3bafade
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 29 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@
import org.jetbrains.annotations.Nullable;

import net.minecraft.block.entity.SignBlockEntity;
import net.minecraft.class_8791;
import net.minecraft.entity.Entity;
import net.minecraft.entity.damage.DamageSource;
import net.minecraft.entity.passive.AbstractHorseEntity;
import net.minecraft.inventory.Inventory;
import net.minecraft.network.packet.c2s.common.SyncedClientOptions;
import net.minecraft.scoreboard.AbstractTeam;
import net.minecraft.screen.NamedScreenHandlerFactory;
import net.minecraft.server.network.ServerPlayerEntity;
Expand Down Expand Up @@ -102,7 +102,7 @@ private record FakePlayerKey(ServerWorld world, GameProfile profile) { }
private static final Map<FakePlayerKey, FakePlayer> FAKE_PLAYER_MAP = new MapMaker().weakValues().makeMap();

protected FakePlayer(ServerWorld world, GameProfile profile) {
super(world.getServer(), world, profile, class_8791.method_53821());
super(world.getServer(), world, profile, SyncedClientOptions.createDefault());

this.networkHandler = new FakePlayerNetworkHandler(this);
}
Expand All @@ -111,7 +111,7 @@ protected FakePlayer(ServerWorld world, GameProfile profile) {
public void tick() { }

@Override
public void setClientSettings(class_8791 settings) { }
public void setClientOptions(SyncedClientOptions settings) { }

@Override
public void increaseStat(Stat<?> stat, int amount) { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,20 @@

import org.jetbrains.annotations.Nullable;

import net.minecraft.class_8792;
import net.minecraft.network.ClientConnection;
import net.minecraft.network.NetworkSide;
import net.minecraft.network.PacketCallbacks;
import net.minecraft.network.listener.PacketListener;
import net.minecraft.network.packet.Packet;
import net.minecraft.server.network.ConnectedClientData;
import net.minecraft.server.network.ServerPlayNetworkHandler;
import net.minecraft.server.network.ServerPlayerEntity;

public class FakePlayerNetworkHandler extends ServerPlayNetworkHandler {
private static final ClientConnection FAKE_CONNECTION = new FakeClientConnection();

public FakePlayerNetworkHandler(ServerPlayerEntity player) {
super(player.getServer(), FAKE_CONNECTION, player, new class_8792(null, 0, null));
super(player.getServer(), FAKE_CONNECTION, player, ConnectedClientData.createDefault(player.getGameProfile()));
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;

import net.minecraft.class_8792;
import net.minecraft.network.ClientConnection;
import net.minecraft.server.PlayerManager;
import net.minecraft.server.network.ConnectedClientData;
import net.minecraft.server.network.ServerPlayerEntity;

import net.fabricmc.fabric.api.event.lifecycle.v1.ServerLifecycleEvents;
Expand All @@ -34,7 +34,7 @@ public class PlayerManagerMixin {
method = "onPlayerConnect",
at = @At(value = "INVOKE", target = "net/minecraft/network/packet/s2c/play/SynchronizeRecipesS2CPacket.<init>(Ljava/util/Collection;)V")
)
private void hookOnPlayerConnect(ClientConnection connection, ServerPlayerEntity player, class_8792 arg, CallbackInfo ci) {
private void hookOnPlayerConnect(ClientConnection connection, ServerPlayerEntity player, ConnectedClientData arg, CallbackInfo ci) {
ServerLifecycleEvents.SYNC_DATA_PACK_CONTENTS.invoker().onSyncDataPackContents(player, true);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,17 @@
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;

import net.minecraft.class_8792;
import net.minecraft.network.ClientConnection;
import net.minecraft.server.PlayerManager;
import net.minecraft.server.network.ConnectedClientData;
import net.minecraft.server.network.ServerPlayerEntity;

import net.fabricmc.fabric.impl.networking.server.ServerNetworkingImpl;

@Mixin(PlayerManager.class)
abstract class PlayerManagerMixin {
@Inject(method = "onPlayerConnect", at = @At(value = "INVOKE", target = "Lnet/minecraft/network/packet/s2c/play/PlayerAbilitiesS2CPacket;<init>(Lnet/minecraft/entity/player/PlayerAbilities;)V"))
private void handlePlayerConnection(ClientConnection connection, ServerPlayerEntity player, class_8792 arg, CallbackInfo ci) {
private void handlePlayerConnection(ClientConnection connection, ServerPlayerEntity player, ConnectedClientData arg, CallbackInfo ci) {
ServerNetworkingImpl.getAddon(player.networkHandler).onClientReady();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;

import net.minecraft.class_8792;
import net.minecraft.network.ClientConnection;
import net.minecraft.network.packet.Packet;
import net.minecraft.network.packet.s2c.common.DisconnectS2CPacket;
import net.minecraft.server.MinecraftServer;
import net.minecraft.server.network.ConnectedClientData;
import net.minecraft.server.network.ServerCommonNetworkHandler;
import net.minecraft.server.network.ServerConfigurationNetworkHandler;
import net.minecraft.server.network.ServerPlayerConfigurationTask;
Expand Down Expand Up @@ -71,7 +71,7 @@ public abstract class ServerConfigurationNetworkHandlerMixin extends ServerCommo
@Unique
private boolean earlyTaskExecution;

public ServerConfigurationNetworkHandlerMixin(MinecraftServer server, ClientConnection connection, class_8792 arg) {
public ServerConfigurationNetworkHandlerMixin(MinecraftServer server, ClientConnection connection, ConnectedClientData arg) {
super(server, connection, arg);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;

import net.minecraft.class_8792;
import net.minecraft.network.ClientConnection;
import net.minecraft.network.packet.Packet;
import net.minecraft.network.packet.s2c.common.DisconnectS2CPacket;
import net.minecraft.server.MinecraftServer;
import net.minecraft.server.network.ConnectedClientData;
import net.minecraft.server.network.ServerCommonNetworkHandler;
import net.minecraft.server.network.ServerPlayNetworkHandler;
import net.minecraft.text.Text;
Expand All @@ -41,7 +41,7 @@ abstract class ServerPlayNetworkHandlerMixin extends ServerCommonNetworkHandler
@Unique
private ServerPlayNetworkAddon addon;

ServerPlayNetworkHandlerMixin(MinecraftServer server, ClientConnection connection, class_8792 arg) {
ServerPlayNetworkHandlerMixin(MinecraftServer server, ClientConnection connection, ConnectedClientData arg) {
super(server, connection, arg);
}

Expand Down
32 changes: 16 additions & 16 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ org.gradle.jvmargs=-Xmx2560M
org.gradle.parallel=true
fabric.loom.multiProjectOptimisation=true

version=0.88.2
minecraft_version=1.20.2-pre1
yarn_version=+build.2
version=0.88.3
minecraft_version=1.20.2-pre2
yarn_version=+build.1
loader_version=0.14.22
installer_version=0.11.1

Expand All @@ -13,39 +13,39 @@ curseforge_minecraft_version=1.20.2-Snapshot

# Do not manually update, use the bumpversions task:
fabric-api-base-version=0.4.32
fabric-api-lookup-api-v1-version=1.6.39
fabric-api-lookup-api-v1-version=1.6.40
fabric-biome-api-v1-version=13.0.11
fabric-block-api-v1-version=1.0.11
fabric-block-view-api-v2-version=1.0.0
fabric-blockrenderlayer-v1-version=1.1.42
fabric-command-api-v1-version=1.2.35
fabric-command-api-v2-version=2.2.14
fabric-commands-v0-version=0.2.52
fabric-containers-v0-version=0.1.68
fabric-content-registries-v0-version=5.0.2
fabric-containers-v0-version=0.1.69
fabric-content-registries-v0-version=5.0.3
fabric-crash-report-info-v1-version=0.2.19
fabric-data-generation-api-v1-version=13.0.1
fabric-data-generation-api-v1-version=13.0.2
fabric-dimensions-v1-version=2.1.55
fabric-entity-events-v1-version=1.5.24
fabric-events-interaction-v0-version=0.6.6
fabric-events-lifecycle-v0-version=0.2.66
fabric-events-interaction-v0-version=0.6.7
fabric-events-lifecycle-v0-version=0.2.67
fabric-game-rule-api-v1-version=1.0.39
fabric-gametest-api-v1-version=1.2.14
fabric-item-api-v1-version=2.1.31
fabric-item-group-api-v1-version=4.0.12
fabric-key-binding-api-v1-version=1.0.37
fabric-keybindings-v0-version=0.2.35
fabric-lifecycle-events-v1-version=2.2.24
fabric-lifecycle-events-v1-version=2.2.25
fabric-loot-api-v2-version=2.0.1
fabric-message-api-v1-version=6.0.0
fabric-mining-level-api-v1-version=2.1.52
fabric-mining-level-api-v1-version=2.1.53
fabric-model-loading-api-v1-version=1.0.4
fabric-models-v0-version=0.4.3
fabric-networking-api-v1-version=3.0.4
fabric-networking-api-v1-version=3.0.5
fabric-object-builder-api-v1-version=12.0.0
fabric-particles-v1-version=1.1.3
fabric-recipe-api-v1-version=2.0.1
fabric-registry-sync-v0-version=3.0.5
fabric-recipe-api-v1-version=2.0.2
fabric-registry-sync-v0-version=4.0.0
fabric-renderer-api-v1-version=3.1.5
fabric-renderer-indigo-version=1.4.5
fabric-renderer-registries-v1-version=3.2.47
Expand All @@ -56,9 +56,9 @@ fabric-rendering-v1-version=3.0.9
fabric-resource-conditions-api-v1-version=2.3.8
fabric-resource-loader-v0-version=0.11.10
fabric-screen-api-v1-version=2.0.10
fabric-screen-handler-api-v1-version=1.3.34
fabric-screen-handler-api-v1-version=1.3.35
fabric-sound-api-v1-version=1.0.13
fabric-transfer-api-v1-version=3.3.5
fabric-transfer-api-v1-version=3.3.6
fabric-transitive-access-wideners-v1-version=5.0.2
fabric-convention-tags-v1-version=1.5.6
fabric-client-tags-api-v1-version=1.1.3

0 comments on commit 3bafade

Please sign in to comment.