SteamWar/BungeeCore
Archiviert
13
2

Add exception log
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Dieser Commit ist enthalten in:
yoyosource 2023-02-18 11:04:29 +01:00
Ursprung 68a2f78e04
Commit 42c23e4521

Datei anzeigen

@ -22,6 +22,8 @@ package de.steamwar.bungeecore.listeners;
import de.steamwar.bungeecore.BungeeCore; import de.steamwar.bungeecore.BungeeCore;
import de.steamwar.bungeecore.Message; import de.steamwar.bungeecore.Message;
import de.steamwar.bungeecore.Storage; import de.steamwar.bungeecore.Storage;
import de.steamwar.bungeecore.sql.SWException;
import de.steamwar.bungeecore.sql.SteamwarUser;
import net.md_5.bungee.BungeeCord; import net.md_5.bungee.BungeeCord;
import net.md_5.bungee.api.connection.Connection; import net.md_5.bungee.api.connection.Connection;
import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.connection.ProxiedPlayer;
@ -80,7 +82,12 @@ public class NonFabricFabricCheck extends BasicListener {
@EventHandler @EventHandler
public void onPlayerDisconnect(PlayerDisconnectEvent e) { public void onPlayerDisconnect(PlayerDisconnectEvent e) {
if (checking.remove(e.getPlayer())) { if (checking.remove(e.getPlayer())) {
logMessage(SteamwarUser.get(e.getPlayer().getUniqueId()), "Player is potentially using rebranded Fabric");
usingFabric.add(e.getPlayer().getUniqueId()); usingFabric.add(e.getPlayer().getUniqueId());
} }
} }
public void logMessage(SteamwarUser user, String reason) {
SWException.log("Bungee", "NonFabricFabricCheck " + user.getUserName() + ": " + reason, "");
}
} }