mirror of
https://github.com/GeyserMC/Floodgate.git
synced 2025-12-20 23:39:27 +00:00
Always change the GameProfile for Floodgate players in Velocity
This commit is contained in:
@@ -143,14 +143,17 @@ public final class VelocityListener {
|
|||||||
FloodgatePlayer player = playerCache.getIfPresent(event.getConnection());
|
FloodgatePlayer player = playerCache.getIfPresent(event.getConnection());
|
||||||
if (player != null) {
|
if (player != null) {
|
||||||
playerCache.invalidate(event.getConnection());
|
playerCache.invalidate(event.getConnection());
|
||||||
// The texture properties addition is to fix the February 2 2022 Mojang authentication changes
|
|
||||||
if (!config.isSendFloodgateData() && !player.isLinked()) {
|
GameProfile profile = new GameProfile(
|
||||||
event.setGameProfile(new GameProfile(
|
|
||||||
player.getCorrectUniqueId(),
|
player.getCorrectUniqueId(),
|
||||||
player.getCorrectUsername(),
|
player.getCorrectUsername(),
|
||||||
Collections.singletonList(new Property("textures", "", ""))
|
Collections.emptyList()
|
||||||
));
|
);
|
||||||
|
// The texture properties addition is to fix the February 2 2022 Mojang authentication changes
|
||||||
|
if (!config.isSendFloodgateData() && !player.isLinked()) {
|
||||||
|
profile = profile.addProperty(new Property("textures", "", ""));
|
||||||
}
|
}
|
||||||
|
event.setGameProfile(profile);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user