diff --git a/frontend/bindings/firefly-launcher/internal/git-service/gitservice.js b/frontend/bindings/firefly-launcher/internal/git-service/gitservice.js index 9ee075e..01c3281 100644 --- a/frontend/bindings/firefly-launcher/internal/git-service/gitservice.js +++ b/frontend/bindings/firefly-launcher/internal/git-service/gitservice.js @@ -43,13 +43,6 @@ export function GetLatestServerVersion() { return $Call.ByID(2918980975); } -/** - * @returns {$CancellablePromise} - */ -export function UnzipProxy() { - return $Call.ByID(2563246729); -} - /** * @returns {$CancellablePromise} */ diff --git a/frontend/bindings/github.com/wailsapp/wails/v3/internal/eventcreate.js b/frontend/bindings/github.com/wailsapp/wails/v3/internal/eventcreate.js new file mode 100644 index 0000000..1ea1058 --- /dev/null +++ b/frontend/bindings/github.com/wailsapp/wails/v3/internal/eventcreate.js @@ -0,0 +1,9 @@ +//@ts-check +// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL +// This file is automatically generated. DO NOT EDIT + +// eslint-disable-next-line @typescript-eslint/ban-ts-comment +// @ts-ignore: Unused imports +import { Create as $Create } from "@wailsio/runtime"; + +Object.freeze($Create.Events); diff --git a/frontend/bindings/github.com/wailsapp/wails/v3/internal/eventdata.d.ts b/frontend/bindings/github.com/wailsapp/wails/v3/internal/eventdata.d.ts new file mode 100644 index 0000000..3dd1807 --- /dev/null +++ b/frontend/bindings/github.com/wailsapp/wails/v3/internal/eventdata.d.ts @@ -0,0 +1,2 @@ +// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL +// This file is automatically generated. DO NOT EDIT diff --git a/frontend/src/helper/proxy.ts b/frontend/src/helper/proxy.ts index 702f71c..1357f07 100644 --- a/frontend/src/helper/proxy.ts +++ b/frontend/src/helper/proxy.ts @@ -23,11 +23,9 @@ export async function UpdateProxy(proxyVersion: string) : Promise { setDownloadType("Downloading proxy...") const [ok, error] = await GitService.DownloadProxyProgress(proxyVersion) if (ok) { - setDownloadType("Unzipping proxy...") - GitService.UnzipProxy() setDownloadType("Download proxy successfully") setProxyVersion(proxyVersion) - setProxyPath("./proxy/FireflyProxy.exe") + setProxyPath("./proxy/firefly-go-proxy.exe") } else { toast.error(error) setDownloadType("Download proxy failed") diff --git a/frontend/src/pages/launcher/index.tsx b/frontend/src/pages/launcher/index.tsx index 8ea4d89..da10bf9 100644 --- a/frontend/src/pages/launcher/index.tsx +++ b/frontend/src/pages/launcher/index.tsx @@ -178,8 +178,6 @@ export default function LauncherPage() { } } - - const handleStartGame = async () => { if (!gamePath) { return diff --git a/go.mod b/go.mod index 335ce06..eeadd20 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module firefly-launcher -go 1.25 +go 1.25.5 require ( github.com/klauspost/compress v1.18.0 diff --git a/internal/git-service/proxy.go b/internal/git-service/proxy.go index 77cfda3..e8e9226 100644 --- a/internal/git-service/proxy.go +++ b/internal/git-service/proxy.go @@ -37,7 +37,7 @@ func (g *GitService) GetLatestProxyVersion() (bool, string, string) { } func (g *GitService) DownloadProxyProgress(version string) (bool, string) { - asset, ok := g.getReleaseAsset(version, constant.ProxyGitUrl, constant.ProxyZipFile) + asset, ok := g.getReleaseAsset(version, constant.ProxyGitUrl, constant.ProxyFile) if !ok { return false, "no release found" } @@ -65,7 +65,3 @@ func (g *GitService) DownloadProxyProgress(version string) (bool, string) { return false, "failed to rename tmp file after retries" } -func (g *GitService) UnzipProxy() { - g.unzipParallel(filepath.Join(constant.ProxyStorageUrl, constant.ProxyZipFile), constant.ProxyStorageUrl) - os.Remove(filepath.Join(constant.ProxyStorageUrl, constant.ProxyZipFile)) -} diff --git a/main.go b/main.go index 96f1956..0c5fcc1 100644 --- a/main.go +++ b/main.go @@ -117,8 +117,6 @@ func main() { systemTray.SetMenu(menu) - - window.RegisterHook(events.Common.WindowClosing, func(e *application.WindowEvent) { app.Event.Emit("window:close") e.Cancel() diff --git a/pkg/constant/constant.go b/pkg/constant/constant.go index 5dd9ee9..87aeb69 100644 --- a/pkg/constant/constant.go +++ b/pkg/constant/constant.go @@ -1,16 +1,16 @@ package constant -const ProxyGitUrl = "https://git.kain.io.vn/api/v1/repos/Firefly-Shelter/Firefly_Proxy/releases" +const ProxyGitUrl = "https://git.kain.io.vn/api/v1/repos/Firefly-Shelter/FireflyGo_Proxy/releases" const ServerGitUrl = "https://git.kain.io.vn/api/v1/repos/Firefly-Shelter/FireflyGo_Local_Archive/releases" const LauncherGitUrl = "https://git.kain.io.vn/api/v1/repos/Firefly-Shelter/Firefly_Launcher/releases" const ServerStorageUrl = "./server" const ProxyStorageUrl = "./proxy" const ServerZipFile = "prebuild_win_x86.zip" -const ProxyZipFile = "64bit.zip" +const ProxyFile = "firefly-go-proxy.exe" const LauncherFile = "firefly-launcher.exe" const TempUrl = "./temp" -const CurrentLauncherVersion = "2.3.1" +const CurrentLauncherVersion = "2.3.2" type ToolFile string