Some changes for GeyserConnect

This commit is contained in:
Camotoy 2021-11-29 22:04:02 -05:00
parent 840318bd8b
commit 51330b8cda
No known key found for this signature in database
GPG Key ID: 7EEFB66FE798081F
2 changed files with 7 additions and 1 deletions

View File

@ -249,7 +249,8 @@ public class GeyserSession implements GeyserConnection, CommandSender {
private Vector2i lastChunkPosition = null;
private int renderDistance;
private boolean sentSpawnPacket;
// Exposed for GeyserConnect usage
protected boolean sentSpawnPacket;
private boolean loggedIn;
private boolean loggingIn;

View File

@ -213,6 +213,11 @@ public class LoginEncryptionUtils {
}
public static void buildAndShowLoginWindow(GeyserSession session) {
if (session.isLoggedIn()) {
// Can happen if a window is cancelled during dimension switch
return;
}
// Set DoDaylightCycle to false so the time doesn't accelerate while we're here
session.setDaylightCycle(false);