From eea57640abcdb2b60f982e910e4761a3ffa9f67b Mon Sep 17 00:00:00 2001
From: MrOkiDoki <0mrokidoki@gmail.com>
Date: Thu, 31 Aug 2023 11:12:05 +0300
Subject: [PATCH] Gameserver null during disconnect fix.ed
---
BattleBitAPI/Server/ServerListener.cs | 6 +++---
CommunityServerAPI.csproj | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/BattleBitAPI/Server/ServerListener.cs b/BattleBitAPI/Server/ServerListener.cs
index a583673..1a9851e 100644
--- a/BattleBitAPI/Server/ServerListener.cs
+++ b/BattleBitAPI/Server/ServerListener.cs
@@ -961,12 +961,12 @@ namespace BattleBitAPI.Server
server.OnPlayerLeftSquad((TPlayer)player, msquad);
}
- @internal.SessionID = 0;
- @internal.GameServer = null;
-
player.OnDisconnected();
server.OnPlayerDisconnected((TPlayer)player);
+ @internal.SessionID = 0;
+ @internal.GameServer = null;
+
if (this.LogLevel.HasFlag(LogLevel.Players))
OnLog(LogLevel.Players, $"{player} has disconnected", player);
}
diff --git a/CommunityServerAPI.csproj b/CommunityServerAPI.csproj
index ba9edc7..94a6a1a 100644
--- a/CommunityServerAPI.csproj
+++ b/CommunityServerAPI.csproj
@@ -18,7 +18,7 @@
https://github.com/MrOkiDoki/BattleBit-Community-Server-API
https://github.com/MrOkiDoki/BattleBit-Community-Server-API
BattleBit
- 1.0.7
+ 1.0.7.1