1
Fork 0
mirror of https://github.com/redstrate/Physis.git synced 2025-04-23 21:17:45 +00:00

Fix patch testing

This commit is contained in:
Joshua Goins 2024-04-20 12:58:29 -04:00
parent 7c63474175
commit 7aeb217e2e

View file

@ -125,7 +125,7 @@ fn xivlauncher_install_patch(game_directory: &str, data_directory: &str, patch_n
let game_dir = format!("Z:\\{}\\{}", game_directory, data_directory); let game_dir = format!("Z:\\{}\\{}", game_directory, data_directory);
// TODO: check for windows systems // TODO: check for windows systems
Command::new("/usr/bin/wine") Command::new("wine")
.args([&patcher_exe, "install", &patch_path, &game_dir]) .args([&patcher_exe, "install", &patch_path, &game_dir])
.output() .output()
.unwrap(); .unwrap();
@ -146,8 +146,16 @@ fn test_patching() {
println!("The game installation is now complete. Now running boot patching..."); println!("The game installation is now complete. Now running boot patching...");
for patch in boot_patches { for patch in boot_patches {
//xivlauncher_install_patch(&xivlauncher_dir, "boot", patch); let patch_dir = env::var("FFXIV_PATCH_DIR").unwrap();
//physis_install_patch(&physis_dir, "boot", patch); if !Path::new(&(patch_dir + "/" + patch)).exists() {
println!("Skipping {} because it doesn't exist locally.", patch);
continue;
}
println!("Installing {}...", patch);
xivlauncher_install_patch(&xivlauncher_dir, "boot", patch);
physis_install_patch(&physis_dir, "boot", patch);
} }
let game_patches = [ let game_patches = [
@ -176,10 +184,16 @@ fn test_patching() {
println!("Boot patching is now complete. Now running game patching..."); println!("Boot patching is now complete. Now running game patching...");
for patch in game_patches { for patch in game_patches {
let patch_dir = env::var("FFXIV_PATCH_DIR").unwrap();
if !Path::new(&(patch_dir + "/" + patch)).exists() {
println!("Skipping {} because it doesn't exist locally.", patch);
continue;
}
println!("Installing {}...", patch); println!("Installing {}...", patch);
//xivlauncher_install_patch(&xivlauncher_dir, "game", patch); xivlauncher_install_patch(&xivlauncher_dir, "game", patch);
//physis_install_patch(&physis_dir, "game", patch); physis_install_patch(&physis_dir, "game", patch);
} }
println!("Game patching is now complete. Proceeding to checksum matching..."); println!("Game patching is now complete. Proceeding to checksum matching...");