2 Commits

Author SHA1 Message Date
f4fe1c6699 v0.5.1 2023-09-18 12:27:01 +02:00
59f1b09337 set current_dir when launching 2023-09-18 12:26:47 +02:00
3 changed files with 3 additions and 2 deletions

2
Cargo.lock generated
View File

@ -30,7 +30,7 @@ dependencies = [
[[package]]
name = "alterware-launcher"
version = "0.5.0"
version = "0.5.1"
dependencies = [
"colored",
"http_req",

View File

@ -1,6 +1,6 @@
[package]
name = "alterware-launcher"
version = "0.5.0"
version = "0.5.1"
edition = "2021"
build = "res/build.rs"

View File

@ -267,6 +267,7 @@ fn launch(file_path: &PathBuf, args: &str) {
println!("Launching {} {}", file_path.display(), args);
std::process::Command::new(file_path)
.args(args.trim().split(' '))
.current_dir(file_path.parent().unwrap())
.spawn()
.expect("Failed to launch the game")
.wait()