fixes the kick on respawn bug

This commit is contained in:
Hanro50 2025-10-15 08:27:25 +02:00
parent 98247bceb2
commit af25f681be

View File

@ -38,7 +38,7 @@ public class CarryOnFabricMod implements ModInitializer {
builder -> builder
.initializer(() -> new CarryOnData(new CompoundTag()))
.persistent(CarryOnData.CODEC)
.syncWith(CarryOnData.STREAM_CODEC, (t, p) -> p.connection != null)
.syncWith(CarryOnData.STREAM_CODEC, (t, p) -> p.connection != null && !p.isRemoved())
.copyOnDeath()
);