1 package ru
.deadsoftware
.cavedroid
.desktop
;
3 import com
.badlogic
.gdx
.Files
;
4 import com
.badlogic
.gdx
.backends
.lwjgl3
.Lwjgl3Application
;
5 import com
.badlogic
.gdx
.backends
.lwjgl3
.Lwjgl3ApplicationConfiguration
;
6 import ru
.deadsoftware
.cavedroid
.CaveGame
;
8 class DesktopLauncher
{
9 public static void main(String
[] arg
) {
10 Lwjgl3ApplicationConfiguration config
= new Lwjgl3ApplicationConfiguration();
11 config
.setWindowIcon(Files
.FileType
.Internal
, "icons/icon256.png", "icons/icon128.png");
12 config
.setTitle("CaveDroid");
13 config
.setWindowedMode(960, 540);
14 config
.useVsync(true);
16 boolean touch
= false;
17 boolean debug
= false;
18 String assetsPath
= null;
20 for (String anArg
: arg
) {
21 if (anArg
.equals("--touch")) {
25 if (anArg
.equals("--debug")) {
29 if (anArg
.startsWith("--assets")) {
30 String
[] splitArg
= anArg
.split("=");
31 if (splitArg
.length
>= 2) {
32 assetsPath
= splitArg
[1];
37 CaveGame caveGame
= new CaveGame(System
.getProperty("user.home") + "/.cavedroid", touch
, assetsPath
);
38 caveGame
.setDebug(debug
);
40 new Lwjgl3Application(caveGame
, config
);