mirror of
https://github.com/SlimeVR/SlimeVR-Server.git
synced 2026-11-24 11:01:20 -08:00
48 lines
1.0 KiB
Java
48 lines
1.0 KiB
Java
package io.eiren.vr;
|
|
|
|
import java.io.File;
|
|
|
|
import io.eiren.gui.VRServerGUI;
|
|
import io.eiren.util.logging.LogManager;
|
|
|
|
public class Main {
|
|
|
|
public static String VERSION = "0.0.18 Test 2";
|
|
|
|
public static VRServer vrServer;
|
|
|
|
@SuppressWarnings("unused")
|
|
public static void main(String[] args) {
|
|
System.setProperty("awt.useSystemAAFontSettings", "on");
|
|
System.setProperty("swing.aatext", "true");
|
|
|
|
File dir = new File("").getAbsoluteFile();
|
|
try {
|
|
LogManager.initialize(new File(dir, "logs/"), dir);
|
|
} catch(Exception e1) {
|
|
e1.printStackTrace();
|
|
}
|
|
|
|
try {
|
|
vrServer = new VRServer();
|
|
vrServer.start();
|
|
new VRServerGUI(vrServer);
|
|
} catch(Throwable e) {
|
|
e.printStackTrace();
|
|
try {
|
|
Thread.sleep(2000L);
|
|
} catch(InterruptedException e2) {
|
|
e.printStackTrace();
|
|
}
|
|
System.exit(1); // Exit in case error happened on init and window not appeared, but some thread started
|
|
} finally {
|
|
try {
|
|
Thread.sleep(2000L);
|
|
} catch(InterruptedException e) {
|
|
e.printStackTrace();
|
|
}
|
|
}
|
|
}
|
|
|
|
}
|