fix: bind packetListenerImpl to Connection when place new photographer (#160)

This commit is contained in:
Helvetica Volubi
2026-07-26 01:38:09 +08:00
parent e6d6562f4f
commit 0724ba3fa9
5 changed files with 22 additions and 15 deletions
@@ -41,6 +41,7 @@ import net.minecraft.network.protocol.game.*;
import net.minecraft.network.protocol.login.ClientboundLoginFinishedPacket;
import net.minecraft.server.MinecraftServer;
import net.minecraft.server.RegistryLayer;
import net.minecraft.server.network.ServerGamePacketListenerImpl;
import net.minecraft.server.packs.repository.KnownPack;
import net.minecraft.tags.TagNetworkSerialization;
import net.minecraft.world.entity.EntityTypes;
@@ -94,6 +95,11 @@ public class Recorder extends Connection {
this.channel = new LocalChannel();
}
public void bind(ServerGamePacketListenerImpl listener) {
this.packetListener = listener;
}
public void start() {
startTime = System.currentTimeMillis();