mirror of
https://gitlab.com/2009scape/09launcher.git
synced 2025-12-09 16:45:54 -07:00
Let's try this.
This commit is contained in:
parent
6d4e3c9dba
commit
6d6bcf62f4
1 changed files with 6 additions and 1 deletions
|
|
@ -9,5 +9,10 @@ fun Component.placeAt(x: Int, y: Int, width: Int, height: Int){
|
||||||
|
|
||||||
fun launchClient() {
|
fun launchClient() {
|
||||||
println("Launching client now.")
|
println("Launching client now.")
|
||||||
Runtime.getRuntime().exec("java -jar " + Settings.SAVE_DIR + File.separator + Settings.SAVE_NAME, null, File(System.getProperty("user.home"))).also { exitProcess(0) }
|
var proc = Runtime.getRuntime().exec("java -jar " + Settings.SAVE_NAME, null, File(System.getProperty("user.home")))
|
||||||
|
if(proc.isAlive){
|
||||||
|
exitProcess(0)
|
||||||
|
} else {
|
||||||
|
MainWindow.loadingLabel.text = "Error starting the client."
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue