forked from BLOCKFANTASY/LOOHP-Limbo
Do not stop server when receving unknown flags
This commit is contained in:
parent
c77c700fac
commit
1040e75ca9
2
pom.xml
2
pom.xml
|
|
@ -4,7 +4,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>com.loohp</groupId>
|
||||
<artifactId>Limbo</artifactId>
|
||||
<version>0.3.7-ALPHA</version>
|
||||
<version>0.3.8-ALPHA</version>
|
||||
<build>
|
||||
<sourceDirectory>src/main/java</sourceDirectory>
|
||||
<resources>
|
||||
|
|
|
|||
|
|
@ -71,14 +71,14 @@ public class Limbo {
|
|||
|
||||
public static void main(String args[]) throws IOException, ParseException, NumberFormatException, ClassNotFoundException, InterruptedException {
|
||||
for (String flag : args) {
|
||||
if (flag.equals("--nogui")) {
|
||||
if (flag.equals("--nogui") || flag.equals("nogui")) {
|
||||
noGui = true;
|
||||
} else {
|
||||
} else if (flag.equals("--help")) {
|
||||
System.out.println("Accepted flags:");
|
||||
System.out.println(" --nogui ");
|
||||
System.out.println();
|
||||
System.out.println("Press [enter] to quit");
|
||||
System.out.println(" --nogui <- Disable the GUI");
|
||||
System.exit(0);
|
||||
} else {
|
||||
System.out.println("Unknown flag: \"" + flag + "\". Ignoring...");
|
||||
}
|
||||
}
|
||||
if (GraphicsEnvironment.isHeadless()) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue