Default debug to false; enable with -debug

This commit is contained in:
KingRainbow44 2023-05-30 13:28:43 -04:00
parent 385b6fbd7c
commit 999d3c739f
No known key found for this signature in database
GPG Key ID: FC2CB64B00D257BE
2 changed files with 8 additions and 4 deletions

View File

@ -7,7 +7,7 @@ import java.util.Arrays;
public final class GameConstants {
public static String VERSION = "3.7.0";
public static final boolean DEBUG = true;
public static boolean DEBUG = false;
public static final int DEFAULT_TEAMS = 4;
public static final int MAX_TEAMS = 10;

View File

@ -1,17 +1,19 @@
package emu.grasscutter.utils;
import static emu.grasscutter.config.Configuration.*;
import ch.qos.logback.classic.Level;
import ch.qos.logback.classic.Logger;
import emu.grasscutter.BuildConfig;
import emu.grasscutter.GameConstants;
import emu.grasscutter.Grasscutter;
import emu.grasscutter.net.packet.PacketOpcodesUtils;
import emu.grasscutter.tools.Dumpers;
import org.slf4j.LoggerFactory;
import java.util.HashMap;
import java.util.Map;
import java.util.function.Function;
import org.slf4j.LoggerFactory;
import static emu.grasscutter.config.Configuration.*;
/** A parser for start-up arguments. */
public interface StartupArguments {
@ -136,6 +138,8 @@ public interface StartupArguments {
// Set the main logger to debug.
Grasscutter.getLogger().setLevel(DEBUG_MODE_INFO.serverLoggerLevel);
Grasscutter.getLogger().debug("The logger is now running in debug mode.");
// Set the server to debug.
GameConstants.DEBUG = true;
return false;
}