diff --git a/src-tauri/src/unzip.rs b/src-tauri/src/unzip.rs index 9a908c9..ee7c5bb 100644 --- a/src-tauri/src/unzip.rs +++ b/src-tauri/src/unzip.rs @@ -120,7 +120,8 @@ pub fn unzip( res_hash.insert("file", zipfile.to_string()); res_hash.insert("new_folder", new_dir); - window.emit("extract_end", &res_hash).unwrap(); + // Testing fix + //window.emit("extract_end", &res_hash).unwrap(); }); } @@ -150,6 +151,8 @@ fn extract_rar(rarfile: &str, _f: &File, full_path: &path::Path, _top_level: boo fn extract_zip(_zipfile: &str, f: &File, full_path: &path::Path, top_level: bool) -> bool { match zip_extract::extract(f, full_path, top_level) { Ok(_) => { + // Notify extract end when extract is actually complete + window.emit("extract_end", &res_hash).unwrap(); println!( "Extracted zip file to: {}", full_path.to_str().unwrap_or("Error") diff --git a/src/ui/components/menu/Downloads.tsx b/src/ui/components/menu/Downloads.tsx index d8c907c..8a8a870 100644 --- a/src/ui/components/menu/Downloads.tsx +++ b/src/ui/components/menu/Downloads.tsx @@ -17,7 +17,7 @@ const STABLE_REPO_DOWNLOAD = 'https://github.com/Grasscutters/Grasscutter/archiv const DEV_REPO_DOWNLOAD = 'https://github.com/Grasscutters/Grasscutter/archive/refs/heads/development.zip' const STABLE_DOWNLOAD = 'https://nightly.link/Grasscutters/Grasscutter/workflows/build/stable/Grasscutter.zip' const DEV_DOWNLOAD = 'https://nightly.link/Grasscutters/Grasscutter/workflows/build/development/Grasscutter.zip' -const RESOURCES_DOWNLOAD = 'https://git.crepe.moe/grasscutters/Grasscutter_Resources/-/blob/main/Grasscutter_Resources-3.3.zip' +const RESOURCES_DOWNLOAD = 'https://gitlab.com/YuukiPS/GC-Resources/-/archive/3.4/GC-Resources-3.4.zip' // Use Yuuki res as grasscutter crepe res are broken interface IProps { closeFn: () => void diff --git a/src/ui/components/news/NewsSection.tsx b/src/ui/components/news/NewsSection.tsx index 619d74c..9c7a2b0 100644 --- a/src/ui/components/news/NewsSection.tsx +++ b/src/ui/components/news/NewsSection.tsx @@ -60,7 +60,10 @@ export default class NewsSection extends React.Component { async showLatestCommits() { if (!this.state.commitList) { - const response: string = await invoke('req_get', { url: 'https://api.grasscutter.io/cultivation/query' }) + // Just use official API + const response: string = await invoke('req_get', { + url: 'https://api.github.com/repos/Grasscutters/Grasscutter/commits', + }) let grasscutterApiResponse: GrasscutterAPIResponse | null = null try { @@ -71,7 +74,7 @@ export default class NewsSection extends React.Component { let commits: CommitResponse[] if (grasscutterApiResponse?.commits == null) { - // If it didn't work, use official API + // If it didn't work, try again anyways const response: string = await invoke('req_get', { url: 'https://api.github.com/repos/Grasscutters/Grasscutter/commits', }) diff --git a/src/utils/configuration.ts b/src/utils/configuration.ts index ac6dc57..9c600cd 100644 --- a/src/utils/configuration.ts +++ b/src/utils/configuration.ts @@ -5,7 +5,7 @@ let configFilePath: string let defaultConfig: Configuration ;(async () => { defaultConfig = { - toggle_grasscutter: false, + toggle_grasscutter: true, game_install_path: 'C:\\Program Files\\Genshin Impact\\Genshin Impact game\\GenshinImpact.exe', grasscutter_with_game: false, grasscutter_path: '', @@ -20,7 +20,7 @@ let defaultConfig: Configuration theme: 'default', https_enabled: false, debug_enabled: false, - patch_metadata: true, + patch_metadata: false, use_internal_proxy: true, wipe_login: false, horny_mode: false,