iw4 default arg -stdout; add cfg.engine

This commit is contained in:
2023-11-13 15:26:28 +01:00
parent 3f6de0350b
commit 35a1d1866f
3 changed files with 30 additions and 0 deletions

View File

@@ -40,3 +40,13 @@ pub fn save_value(config_path: PathBuf, key: &str, value: bool) {
}
save(config_path, config);
}
pub fn save_value_s(config_path: PathBuf, key: &str, value: String) {
let mut config = load(config_path.clone());
match key {
"args" => config.args = value.to_string(),
"engine" => config.engine = value.to_string(),
_ => (),
}
save(config_path, config);
}