mirror of
https://github.com/LCE-Hub/LCE-Emerald-Launcher.git
synced 2026-07-19 08:47:19 +00:00
feat(lceonline): -token for client
This commit is contained in:
parent
2593979b4f
commit
87f7787d9a
BIN
public/images/lce_online.png
Normal file
BIN
public/images/lce_online.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 41 KiB |
|
|
@ -77,6 +77,17 @@ export const BASE_EDITIONS = [
|
|||
logo: "/images/moonEdition.png",
|
||||
panorama: "moonedition",
|
||||
},
|
||||
{
|
||||
id: "lceonline",
|
||||
name: "LCE Online Client",
|
||||
desc: "Restoring the classic LCE online experience with friends, world hosting, leaderboards & more.",
|
||||
url: "https://github.com/lceonline/MCLEClient/releases/download/v1.0.0b/LCENWindows64.zip",
|
||||
titleImage: "/images/lceonline.png",
|
||||
supportsSlimSkins: false,
|
||||
logo: "/images/lce_online.png",
|
||||
panorama: "vanilla_tu19",
|
||||
lceOnline: true,
|
||||
},
|
||||
];
|
||||
|
||||
const PARTNERSHIP_SERVERS = [
|
||||
|
|
@ -481,10 +492,18 @@ export function useGameManager({
|
|||
setIsGameRunning(true);
|
||||
try {
|
||||
getCurrentWindow().minimize();
|
||||
const currentEdition = editions.find((e) => e.instanceId === profile);
|
||||
await TauriService.launchGame(
|
||||
profile,
|
||||
PARTNERSHIP_SERVERS,
|
||||
extraLaunchArgs,
|
||||
currentEdition?.lceOnline
|
||||
? extraLaunchArgs!.concat([
|
||||
"-token",
|
||||
localStorage.getItem("lceonline_session")
|
||||
? JSON.parse(localStorage.getItem("lceonline_session")!).accessToken
|
||||
: "",
|
||||
])
|
||||
: extraLaunchArgs,
|
||||
);
|
||||
} catch (e: unknown) {
|
||||
console.error(e);
|
||||
|
|
@ -635,4 +654,4 @@ export function useGameManager({
|
|||
updateCustomization,
|
||||
saveCustomPath,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@ export interface Edition {
|
|||
comingSoon?: boolean;
|
||||
category?: string[];
|
||||
officialDLC?: string;
|
||||
lceOnline?: boolean;
|
||||
}
|
||||
|
||||
export interface CustomEditionInput {
|
||||
|
|
|
|||
Loading…
Reference in a new issue