Separated interface configuration.
This commit is contained in:
		
							
								
								
									
										15
									
								
								L2J_Mobius_C6_Interlude/dist/game/config/Interface.ini
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								L2J_Mobius_C6_Interlude/dist/game/config/Interface.ini
									
									
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,15 @@ | ||||
| # --------------------------------------------------------------------------- | ||||
| # Interface Settings | ||||
| # --------------------------------------------------------------------------- | ||||
|  | ||||
| # Enable L2jMobius GUI when OS supports it. | ||||
| # Provides access to admin commands without the need to be online. | ||||
| # Warning! Do not disable if you use Gameserver.exe | ||||
| #          because server will run in the background! | ||||
| # Default: True | ||||
| EnableGUI = True | ||||
|  | ||||
| # Dark theme. | ||||
| # Use a dark version of the Nimbus theme. | ||||
| # Default: True | ||||
| DarkTheme = True | ||||
| @@ -130,23 +130,6 @@ InstantThreadPoolCount = 120 | ||||
| UrgentPacketThreadCoreSize = 40 | ||||
|  | ||||
|  | ||||
| # --------------------------------------------------------------------------- | ||||
| # Look and feel | ||||
| # --------------------------------------------------------------------------- | ||||
|  | ||||
| # Enable L2jMobius GUI when OS supports it. | ||||
| # Provides access to admin commands without the need to be online. | ||||
| # Warning! Do not disable if you use Gameserver.exe | ||||
| #          because server will run in the background! | ||||
| # Default: True | ||||
| EnableGUI = True | ||||
|  | ||||
| # Dark theme. | ||||
| # Use a dark version of the Nimbus theme. | ||||
| # Default: True | ||||
| DarkTheme = True | ||||
|  | ||||
|  | ||||
| # --------------------------------------------------------------------------- | ||||
| # Misc Player Settings | ||||
| # --------------------------------------------------------------------------- | ||||
|   | ||||
							
								
								
									
										15
									
								
								L2J_Mobius_C6_Interlude/dist/login/config/Interface.ini
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								L2J_Mobius_C6_Interlude/dist/login/config/Interface.ini
									
									
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,15 @@ | ||||
| # --------------------------------------------------------------------------- | ||||
| # Interface Settings | ||||
| # --------------------------------------------------------------------------- | ||||
|  | ||||
| # Enable L2jMobius GUI when OS supports it. | ||||
| # Provides access to admin commands without the need to be online. | ||||
| # Warning! Do not disable if you use Gameserver.exe | ||||
| #          because server will run in the background! | ||||
| # Default: True | ||||
| EnableGUI = True | ||||
|  | ||||
| # Dark theme. | ||||
| # Use a dark version of the Nimbus theme. | ||||
| # Default: True | ||||
| DarkTheme = True | ||||
| @@ -54,23 +54,6 @@ Password = | ||||
| MaximumDbConnections = 5 | ||||
|  | ||||
|  | ||||
| # --------------------------------------------------------------------------- | ||||
| # Look and feel | ||||
| # --------------------------------------------------------------------------- | ||||
|  | ||||
| # Enable L2jMobius GUI when OS supports it. | ||||
| # Provides access to admin commands without the need to be online. | ||||
| # Warning! Do not disable if you use Gameserver.exe | ||||
| #          because server will run in the background! | ||||
| # Default: True | ||||
| EnableGUI = True | ||||
|  | ||||
| # Dark theme. | ||||
| # Use a dark version of the Nimbus theme. | ||||
| # Default: True | ||||
| DarkTheme = True | ||||
|  | ||||
|  | ||||
| # --------------------------------------------------------------------------- | ||||
| # Automatic Database Backup Settings | ||||
| # --------------------------------------------------------------------------- | ||||
|   | ||||
| @@ -69,6 +69,8 @@ public class Config | ||||
| 	private static final String FILTER_FILE = "./config/chatfilter.txt"; | ||||
| 	private static final String HEXID_FILE = "./config/hexid.txt"; | ||||
| 	private static final String IPCONFIG_FILE = "./config/ipconfig.xml"; | ||||
| 	// interface | ||||
| 	public static final String INTERFACE_CONFIG_FILE = "./config/Interface.ini"; | ||||
| 	// main | ||||
| 	private static final String ACCESS_CONFIG_FILE = "./config/main/Access.ini"; | ||||
| 	private static final String CHARACTER_CONFIG_FILE = "./config/main/Character.ini"; | ||||
| @@ -85,7 +87,7 @@ public class Config | ||||
| 	private static final String PVP_CONFIG_FILE = "./config/main/PvP.ini"; | ||||
| 	private static final String RAIDBOSS_CONFIG_FILE = "./config/main/RaidBoss.ini"; | ||||
| 	private static final String RATES_CONFIG_FILE = "./config/main/Rates.ini"; | ||||
| 	public static final String SERVER_CONFIG_FILE = "./config/main/Server.ini"; | ||||
| 	private static final String SERVER_CONFIG_FILE = "./config/main/Server.ini"; | ||||
| 	private static final String SEVENSIGNS_CONFIG_FILE = "./config/main/SevenSigns.ini"; | ||||
| 	public static final String SIEGE_CONFIG_FILE = "./config/main/Siege.ini"; | ||||
| 	// protected | ||||
| @@ -113,7 +115,7 @@ public class Config | ||||
| 	private static final String EVENT_REBIRTH_CONFIG_FILE = "./config/custom/Rebirth.ini"; | ||||
| 	private static final String EVENT_WEDDING_CONFIG_FILE = "./config/custom/Wedding.ini"; | ||||
| 	// login | ||||
| 	public static final String LOGIN_CONFIG_FILE = "./config/LoginServer.ini"; | ||||
| 	private static final String LOGIN_CONFIG_FILE = "./config/LoginServer.ini"; | ||||
| 	 | ||||
| 	// -------------------------------------------------- | ||||
| 	// Variable Definitions | ||||
| @@ -1167,8 +1169,6 @@ public class Config | ||||
| 	public static int SCHEDULED_THREAD_POOL_COUNT; | ||||
| 	public static int INSTANT_THREAD_POOL_COUNT; | ||||
| 	public static int IO_PACKET_THREAD_CORE_SIZE; | ||||
| 	public static boolean ENABLE_GUI; | ||||
| 	public static boolean DARK_THEME; | ||||
| 	public static String CNAME_TEMPLATE; | ||||
| 	public static String PET_NAME_TEMPLATE; | ||||
| 	public static String CLAN_NAME_TEMPLATE; | ||||
| @@ -1194,6 +1194,9 @@ public class Config | ||||
| 	public static boolean ACCEPT_NEW_GAMESERVER; | ||||
| 	public static boolean AUTO_CREATE_ACCOUNTS; | ||||
| 	 | ||||
| 	public static boolean ENABLE_GUI; | ||||
| 	public static boolean DARK_THEME; | ||||
| 	 | ||||
| 	public static void loadAccessConfig() | ||||
| 	{ | ||||
| 		final PropertiesParser accessConfig = new PropertiesParser(ACCESS_CONFIG_FILE); | ||||
|   | ||||
| @@ -152,11 +152,11 @@ public class GameServer | ||||
| 		final long serverLoadStart = Chronos.currentTimeMillis(); | ||||
| 		 | ||||
| 		// GUI | ||||
| 		final PropertiesParser serverSettings = new PropertiesParser(Config.SERVER_CONFIG_FILE); | ||||
| 		Config.ENABLE_GUI = serverSettings.getBoolean("EnableGUI", true); | ||||
| 		final PropertiesParser interfaceSettings = new PropertiesParser(Config.INTERFACE_CONFIG_FILE); | ||||
| 		Config.ENABLE_GUI = interfaceSettings.getBoolean("EnableGUI", true); | ||||
| 		if (Config.ENABLE_GUI && !GraphicsEnvironment.isHeadless()) | ||||
| 		{ | ||||
| 			Config.DARK_THEME = serverSettings.getBoolean("DarkTheme", true); | ||||
| 			Config.DARK_THEME = interfaceSettings.getBoolean("DarkTheme", true); | ||||
| 			System.out.println("GameServer: Running in GUI mode."); | ||||
| 			new Gui(); | ||||
| 		} | ||||
|   | ||||
| @@ -64,11 +64,11 @@ public class LoginServer | ||||
| 	private LoginServer() throws Exception | ||||
| 	{ | ||||
| 		// GUI | ||||
| 		final PropertiesParser serverSettings = new PropertiesParser(Config.LOGIN_CONFIG_FILE); | ||||
| 		Config.ENABLE_GUI = serverSettings.getBoolean("EnableGUI", true); | ||||
| 		final PropertiesParser interfaceSettings = new PropertiesParser(Config.INTERFACE_CONFIG_FILE); | ||||
| 		Config.ENABLE_GUI = interfaceSettings.getBoolean("EnableGUI", true); | ||||
| 		if (Config.ENABLE_GUI && !GraphicsEnvironment.isHeadless()) | ||||
| 		{ | ||||
| 			Config.DARK_THEME = serverSettings.getBoolean("DarkTheme", true); | ||||
| 			Config.DARK_THEME = interfaceSettings.getBoolean("DarkTheme", true); | ||||
| 			System.out.println("LoginServer: Running in GUI mode."); | ||||
| 			new Gui(); | ||||
| 		} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 MobiusDevelopment
					MobiusDevelopment