diff --git a/api/src/main/java/com/viaversion/viaversion/api/connection/UserConnection.java b/api/src/main/java/com/viaversion/viaversion/api/connection/UserConnection.java index e35990000..ebab009d4 100644 --- a/api/src/main/java/com/viaversion/viaversion/api/connection/UserConnection.java +++ b/api/src/main/java/com/viaversion/viaversion/api/connection/UserConnection.java @@ -90,8 +90,8 @@ public interface UserConnection { void addEntityTracker(Class protocolClass, EntityTracker tracker); /** - * Clear all the stored objects. - * Used for bungee when switching servers. + * Clear stored objects and entity trackers. + * Used for Bungee when switching servers. */ void clearStoredObjects(); diff --git a/common/src/main/java/com/viaversion/viaversion/connection/UserConnectionImpl.java b/common/src/main/java/com/viaversion/viaversion/connection/UserConnectionImpl.java index ce94d0127..385c8fbc8 100644 --- a/common/src/main/java/com/viaversion/viaversion/connection/UserConnectionImpl.java +++ b/common/src/main/java/com/viaversion/viaversion/connection/UserConnectionImpl.java @@ -114,6 +114,7 @@ public class UserConnectionImpl implements UserConnection { @Override public void clearStoredObjects() { storedObjects.clear(); + entityTrackers.clear(); } @Override