mirror of
https://github.com/TotalFreedomMC/TF-PlotSquared.git
synced 2024-12-23 00:15:06 +00:00
Fixes #2800 Allow to wrap OfflinePlayers in 1.15.2
This commit is contained in:
parent
ed2e9a80ed
commit
d864792d09
1 changed files with 4 additions and 1 deletions
|
@ -90,7 +90,10 @@ public class OfflinePlayerUtil {
|
|||
Object worldServer = getWorldServer();
|
||||
Class<?> playerInteractClass = getNmsClass("PlayerInteractManager");
|
||||
Class<?> worldClass = getNmsClass("World");
|
||||
Constructor c = makeConstructor(playerInteractClass, worldClass);
|
||||
Constructor<?> c = makeConstructor(playerInteractClass, worldClass);
|
||||
if (c == null) {
|
||||
c = makeConstructor(playerInteractClass, getNmsClass("WorldServer"));
|
||||
}
|
||||
return callConstructor(c, worldServer);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue