DebugMessage

public class DebugMessage

Utility class for managing debug messages. Debug messages are only shown when debug mode is enabled for a specific player.

Functions

Link copied to clipboard
public static void damageSummary(Player player, String line)
Emits a compact single-line damage summary to the server log for the given player.
Link copied to clipboard
public static boolean isAnyDebugEnabled()
Checks if any player has debug mode enabled.
Link copied to clipboard
public static boolean isDebugEnabled(Player player)
Checks if debug mode is enabled for a player.
Link copied to clipboard
public static void log(String message)
Logs a debug message to console if any player has debug enabled.
public static void log(Player player, String message)
Logs a debug message to console if the specified player has debug enabled.
Link copied to clipboard
public static void send(Player player, String message)
Sends a debug message directly to a player if they have debug enabled, and mirrors the message (color codes stripped) to the server log.
Link copied to clipboard
public static void shutdown()
Clears all debug players (for shutdown).
Link copied to clipboard
public static String stripColors(String message)
Strips Bukkit / magmacore chat colour codes from a message so it can be written to the server log without escape noise.
Link copied to clipboard
public static boolean toggleDebug(Player player)
Toggles debug mode for a player.