use dirs::home_dir; use std::{ env, path::{Path, PathBuf}, }; pub fn get_local_data_directory() -> PathBuf { dirs::data_local_dir().unwrap().join("FCLauncher") } pub fn get_data_directory() -> PathBuf { dirs::data_dir().unwrap().join("FCLauncher") } pub fn get_java_executable() -> String { return format!( "java{}", if env::consts::OS == "windows" { ".exe" } else { "" } ); } pub fn get_prism_executable() -> String { return format!( "{}", if env::consts::OS == "windows" { "prismlauncher.exe" } else { "PrismLauncher" } ); }