mirror of
https://github.com/craftycodie/OnlineModeFix.git
synced 2025-08-04 01:15:58 -04:00
Removed some logs.
This commit is contained in:
parent
afb2b257aa
commit
31e30fa3c0
@ -1,5 +1,5 @@
|
||||
name: MineOnlineBroadcast
|
||||
version: 1.1.3
|
||||
version: 1.1.5
|
||||
description: Lists a server on mineonline.codie.gg/servers
|
||||
author: codieradical
|
||||
authors: [Codie]
|
||||
|
@ -154,11 +154,11 @@ public class MineOnlineBroadcast extends Plugin {
|
||||
serverIcon = encoder.encodeToString(bytes);
|
||||
serverIcon = serverIcon.replace(System.lineSeparator(), "");
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
// e.printStackTrace();
|
||||
}
|
||||
}
|
||||
} catch (IIOException ex) {
|
||||
ex.printStackTrace();
|
||||
// ex.printStackTrace();
|
||||
}
|
||||
|
||||
serverUUID = MineOnlineAPI.listServer(
|
||||
@ -177,7 +177,7 @@ public class MineOnlineBroadcast extends Plugin {
|
||||
serverIcon
|
||||
);
|
||||
} catch (IOException ex) {
|
||||
ex.printStackTrace();
|
||||
// ex.printStackTrace();
|
||||
// ignore.
|
||||
}
|
||||
}
|
||||
|
@ -24,6 +24,12 @@ public class MineOnlineBroadcastListener extends PlayerListener {
|
||||
discord.sendDiscordMessage("", "**" + colorCodeProvider.removeColorCodes(event.getPlayer().getName()) + "** joined the game.");
|
||||
}
|
||||
|
||||
public void onPlayerJoin(PlayerJoinEvent event) {
|
||||
MineOnlineBroadcastPlugin.lastPing = 0;
|
||||
if (discord != null)
|
||||
discord.sendDiscordMessage("", "**" + colorCodeProvider.removeColorCodes(event.getPlayer().getName()) + "** joined the game.");
|
||||
}
|
||||
|
||||
public void onPlayerKick(PlayerKickEvent event) {
|
||||
MineOnlineBroadcastPlugin.lastPing = 0;
|
||||
if (discord != null)
|
||||
|
@ -129,11 +129,11 @@ public class MineOnlineBroadcastPlugin extends JavaPlugin {
|
||||
serverIcon = encoder.encodeToString(bytes);
|
||||
serverIcon = serverIcon.replace(System.lineSeparator(), "");
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
// e.printStackTrace();
|
||||
}
|
||||
}
|
||||
} catch (IIOException ex) {
|
||||
ex.printStackTrace();
|
||||
// ex.printStackTrace();
|
||||
}
|
||||
|
||||
serverUUID = MineOnlineAPI.listServer(
|
||||
@ -250,7 +250,12 @@ public class MineOnlineBroadcastPlugin extends JavaPlugin {
|
||||
}
|
||||
|
||||
this.listener = new MineOnlineBroadcastListener(discord);
|
||||
try {
|
||||
ClassLoader.getSystemClassLoader().loadClass("org.bukkit.event.player.PlayerJoinEvent");
|
||||
this.getServer().getPluginManager().registerEvent(Event.Type.PLAYER_JOIN, this.listener, Event.Priority.Highest, this);
|
||||
} catch (ClassNotFoundException ex) {
|
||||
this.getServer().getPluginManager().registerEvent(Event.Type.PLAYER_LOGIN, this.listener, Event.Priority.Lowest, this);
|
||||
}
|
||||
this.getServer().getPluginManager().registerEvent(Event.Type.PLAYER_QUIT, this.listener, Event.Priority.Highest, this);
|
||||
this.getServer().getPluginManager().registerEvent(Event.Type.PLAYER_KICK, this.listener, Event.Priority.Highest, this);
|
||||
this.getServer().getPluginManager().registerEvent(Event.Type.PLAYER_CHAT, this.listener, Event.Priority.Highest, this);
|
||||
|
Loading…
x
Reference in New Issue
Block a user