From 8007cdd706122bdbda8febf904b108ef3bc3ddf8 Mon Sep 17 00:00:00 2001 From: libraryaddict Date: Sun, 25 Jul 2021 01:09:02 +1200 Subject: [PATCH] Fix wrong version for paper check in tracker fetch --- .../libraryaddict/disguise/utilities/DisguiseUtilities.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/me/libraryaddict/disguise/utilities/DisguiseUtilities.java b/src/main/java/me/libraryaddict/disguise/utilities/DisguiseUtilities.java index d63ca57f..39a097cf 100644 --- a/src/main/java/me/libraryaddict/disguise/utilities/DisguiseUtilities.java +++ b/src/main/java/me/libraryaddict/disguise/utilities/DisguiseUtilities.java @@ -1854,7 +1854,7 @@ public class DisguiseUtilities { // TODO Store reflection fields // If the tracker exists. Remove himself from his tracker - if (!isRunningPaper() || NmsVersion.v1_16.isSupported()) { + if (!isRunningPaper() || NmsVersion.v1_17.isSupported()) { Object trackedPlayersObj = ReflectionManager.getNmsField("EntityTrackerEntry", "trackedPlayers").get(entityTrackerEntry); ((Set) trackedPlayersObj).remove(ReflectionManager.getPlayerConnectionOrPlayer(player)); @@ -2393,7 +2393,7 @@ public class DisguiseUtilities { // TODO Store reflection fields // Check for code differences in PaperSpigot vs Spigot - if (!isRunningPaper() || NmsVersion.v1_16.isSupported()) { + if (!isRunningPaper() || NmsVersion.v1_17.isSupported()) { // Add himself to his own entity tracker Object trackedPlayersObj = ReflectionManager.getNmsField("EntityTrackerEntry", "trackedPlayers").get(entityTrackerEntry);