Don't print messages to the console without a plugin prefix.
It's bad practice.
Dieser Commit ist enthalten in:
Ursprung
7536815e58
Commit
4e9b5009c8
@ -117,7 +117,7 @@ public class ProtocolLibrary extends JavaPlugin {
|
|||||||
public void onPacketReceiving(PacketEvent event) {
|
public void onPacketReceiving(PacketEvent event) {
|
||||||
Object handle = event.getPacket().getHandle();
|
Object handle = event.getPacket().getHandle();
|
||||||
|
|
||||||
System.out.println(String.format(
|
logger.info(String.format(
|
||||||
"RECEIVING %s@%s from %s.",
|
"RECEIVING %s@%s from %s.",
|
||||||
handle.getClass().getSimpleName(), handle.hashCode(), event.getPlayer().getName()
|
handle.getClass().getSimpleName(), handle.hashCode(), event.getPlayer().getName()
|
||||||
));
|
));
|
||||||
@ -126,7 +126,7 @@ public class ProtocolLibrary extends JavaPlugin {
|
|||||||
public void onPacketSending(PacketEvent event) {
|
public void onPacketSending(PacketEvent event) {
|
||||||
Object handle = event.getPacket().getHandle();
|
Object handle = event.getPacket().getHandle();
|
||||||
|
|
||||||
System.out.println(String.format(
|
logger.info(String.format(
|
||||||
"SENDING %s@%s from %s.",
|
"SENDING %s@%s from %s.",
|
||||||
handle.getClass().getSimpleName(), handle.hashCode(), event.getPlayer().getName()
|
handle.getClass().getSimpleName(), handle.hashCode(), event.getPlayer().getName()
|
||||||
));
|
));
|
||||||
|
@ -205,7 +205,7 @@ class PacketSendingQueue {
|
|||||||
|
|
||||||
} catch (PlayerLoggedOutException e) {
|
} catch (PlayerLoggedOutException e) {
|
||||||
System.out.println(String.format(
|
System.out.println(String.format(
|
||||||
"Warning: Dropped packet index %s of ID %s",
|
"[ProtocolLib] Warning: Dropped packet index %s of ID %s",
|
||||||
marker.getOriginalSendingIndex(), event.getPacketID()
|
marker.getOriginalSendingIndex(), event.getPacketID()
|
||||||
));
|
));
|
||||||
|
|
||||||
|
@ -198,7 +198,7 @@ public class PlayerInjectionHandler {
|
|||||||
if (injector != null) {
|
if (injector != null) {
|
||||||
return injector.getPlayer();
|
return injector.getPlayer();
|
||||||
} else {
|
} else {
|
||||||
System.out.println("Unable to find stream: " + inputStream);
|
logger.warning("Unable to find stream: " + inputStream);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren