mirror of
https://github.com/zumbiepig/MineXLauncher.git
synced 2025-06-08 09:24:48 +00:00
add webmc oneblock to servers
This commit is contained in:
parent
e5d26b21c9
commit
a3057e4cf9
@ -12,7 +12,7 @@
|
|||||||
<script src="/game/web/clients/eaglerforge/ModGUI.js"></script>
|
<script src="/game/web/clients/eaglerforge/ModGUI.js"></script>
|
||||||
<script src="/game/web/clients/eaglerforge/classes.js"></script>
|
<script src="/game/web/clients/eaglerforge/classes.js"></script>
|
||||||
<script src="/resources/scripts/eagler-launch/1.8.8/eaglermobile-ef.js"></script>
|
<script src="/resources/scripts/eagler-launch/1.8.8/eaglermobile-ef.js"></script>
|
||||||
<script src="/resources/scripts/eagler-launch/1.8.8/eaglerforge.js"></script>
|
<script src="/resources/scripts/eagler-launch/1.8.8/main.js"></script>
|
||||||
</head>
|
</head>
|
||||||
<body id="game_frame"></body>
|
<body id="game_frame"></body>
|
||||||
</html>
|
</html>
|
||||||
|
@ -1,45 +0,0 @@
|
|||||||
// @ts-nocheck
|
|
||||||
window.addEventListener('load', () => {
|
|
||||||
const relayId = Math.floor(Math.random() * 3);
|
|
||||||
window.eaglercraftXOpts = {
|
|
||||||
container: 'game_frame',
|
|
||||||
assetsURI: `${window.location.pathname}/assets.epk`,
|
|
||||||
localesURI: `${window.location.pathname}/lang/`,
|
|
||||||
servers: [
|
|
||||||
{ addr: 'wss://mc.ricenetwork.xyz', name: 'Rice Network' },
|
|
||||||
{ addr: 'wss://mc.lamplifesteal.xyz', name: 'LampLifesteal' },
|
|
||||||
{ addr: 'wss://electronmc.club', name: 'Electron Network' },
|
|
||||||
{ addr: 'wss://play.brickmc.net', name: 'BrickMC' },
|
|
||||||
],
|
|
||||||
relays: [
|
|
||||||
{ addr: 'wss://relay.deev.is/', comment: 'lax1dude relay #1', primary: relayId === 0 },
|
|
||||||
{ addr: 'wss://relay.lax1dude.net/', comment: 'lax1dude relay #2', primary: relayId === 1 },
|
|
||||||
{ addr: 'wss://relay.shhnowisnottheti.me/', comment: 'ayunami relay #1', primary: relayId === 2 },
|
|
||||||
],
|
|
||||||
};
|
|
||||||
|
|
||||||
const storage = {
|
|
||||||
local: {
|
|
||||||
get: function (key: string) {
|
|
||||||
const item = localStorage.getItem('minexlauncher');
|
|
||||||
if (item !== null) {
|
|
||||||
const json = JSON.parse(item);
|
|
||||||
if (json[key] !== undefined) {
|
|
||||||
return json[key];
|
|
||||||
} else {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
|
||||||
|
|
||||||
const urlParams = new URLSearchParams(window.location.search);
|
|
||||||
window.eaglercraftXOpts.joinServer = urlParams.get('server') ?? undefined;
|
|
||||||
window.eaglercraftXOpts.Mods = storage.local.get('mods') ?? [];
|
|
||||||
|
|
||||||
history.replaceState({}, '', '/play');
|
|
||||||
main();
|
|
||||||
});
|
|
@ -6,6 +6,7 @@ window.addEventListener('load', () => {
|
|||||||
assetsURI: `${window.location.pathname}/assets.epk`,
|
assetsURI: `${window.location.pathname}/assets.epk`,
|
||||||
localesURI: `${window.location.pathname}/lang/`,
|
localesURI: `${window.location.pathname}/lang/`,
|
||||||
servers: [
|
servers: [
|
||||||
|
{ addr: 'wss://webmc.xyz/server', name: 'WebMC OneBlock' },
|
||||||
{ addr: 'wss://mc.ricenetwork.xyz', name: 'Rice Network' },
|
{ addr: 'wss://mc.ricenetwork.xyz', name: 'Rice Network' },
|
||||||
{ addr: 'wss://mc.lamplifesteal.xyz', name: 'LampLifesteal' },
|
{ addr: 'wss://mc.lamplifesteal.xyz', name: 'LampLifesteal' },
|
||||||
{ addr: 'wss://electronmc.club', name: 'Electron Network' },
|
{ addr: 'wss://electronmc.club', name: 'Electron Network' },
|
||||||
@ -20,6 +21,7 @@ window.addEventListener('load', () => {
|
|||||||
|
|
||||||
const urlParams = new URLSearchParams(window.location.search);
|
const urlParams = new URLSearchParams(window.location.search);
|
||||||
window.eaglercraftXOpts.joinServer = urlParams.get('server') ?? undefined;
|
window.eaglercraftXOpts.joinServer = urlParams.get('server') ?? undefined;
|
||||||
|
window.eaglercraftXOpts.mods = storage.local.get('mods') ?? [];
|
||||||
|
|
||||||
history.replaceState({}, '', '/play');
|
history.replaceState({}, '', '/play');
|
||||||
main();
|
main();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user