mirror of
https://github.com/Corfirean/coa-server-manager.git
synced 2026-11-21 19:25:56 +00:00
Game client: download and update through the Manager
PLAY turns into UPDATE CLIENT when a tracked client is outdated; with no client linked it offers choosing an existing folder or downloading from the community launcher servers (resumable, hash-verified, free-space checked, progress and stop). Files the player changed are kept on request or moved aside, never silently replaced. Existing clients can be adopted from Settings. Fresh downloads get a realmlist for each installed locale. Fixes zero-length files in the downloader (found by the live probe). Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
7d447b490f
commit
615b3e938d
21 files changed
+1632
-27
No files matched your search
+10
-2
@@ -14,6 +14,7 @@ import { FriendsPage } from "@/screens/FriendsPage";
|
||||
import { ConsolePage } from "@/screens/ConsolePage";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { startServerUpdatePolling, useServerUpdate } from "@/lib/serverUpdate";
|
||||
import { startClientPolling } from "@/lib/clientUpdate";
|
||||
|
||||
type Page = "overview" | "bots" | "server" | "players" | "friends" | "backups" | "console" | "settings";
|
||||
|
||||
@@ -41,8 +42,15 @@ export function Shell(props: {
|
||||
const current = NAV.find((n) => n.id === page)!;
|
||||
const update = useServerUpdate(props.activeId);
|
||||
|
||||
// Look for a server update when the app starts and then every five minutes.
|
||||
useEffect(() => startServerUpdatePolling(props.activeId), [props.activeId]);
|
||||
// Look for a server and a game client update when the app starts and then every five minutes.
|
||||
useEffect(() => {
|
||||
const stopServer = startServerUpdatePolling(props.activeId);
|
||||
const stopClient = startClientPolling(props.activeId);
|
||||
return () => {
|
||||
stopServer();
|
||||
stopClient();
|
||||
};
|
||||
}, [props.activeId]);
|
||||
|
||||
return (
|
||||
<div className="flex h-full">
|
||||
|
||||
Reference in new issue
Block a user