Skip to content

Commit

Permalink
Merge pull request #23 from Stoppedwumm:settings
Browse files Browse the repository at this point in the history
Add settings
  • Loading branch information
Stoppedwumm authored Oct 7, 2024
2 parents 5a037bc + b1d411e commit 5437701
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
![communityIcon_serayq82g91a1](https://github.com/user-attachments/assets/54f4e10c-604d-4fc8-985b-5a42a0d16cf5)

## Build
Prepare all settings/changes you made
Prepare all settings/changes you made.
Then, run `npm run build`

## Contributors
Expand Down
10 changes: 8 additions & 2 deletions binaries/latest.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,15 @@
<meta property="og:locale" content="en-US" />
<meta property="og:type" content="website" />
<meta property="og:title" content="EaglercraftX 1.8" />
<meta property="og:description" content="Play minecraft 1.8 in your browser" />
<meta property="og:description" content="Play minecraft 1.8 in your browser"/>
<script src="settings.js"></script>
<script type="text/javascript">
"use strict";
var relayId = Math.floor(Math.random() * 3);
let adress
if (config.autoJoin) {
adress = config.autoJoinAdress
}

// %%%%%%%%% launch options %%%%%%%%%%%%

Expand All @@ -30,7 +35,8 @@
{ addr: "wss://mc.arch.lol/", name: "Arch MC" }
],
allowBootMenu: false,
enableMinceraft: false
enableMinceraft: false,
joinServer: adress
};

// %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Expand Down
4 changes: 4 additions & 0 deletions binaries/settings.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
const config = {
autoJoin: false,
autoJoinAdress: "wss://mc.arch.lol"
}
1 change: 1 addition & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ app.on('ready', () => {
copyFile(path.join(__dirname, 'binaries', "latest.html"), path.join(homeDirectory, './eaglergrab', 'versions', 'latest.html'))
copyFile(path.join(__dirname, 'binaries', "dev.html"), path.join(homeDirectory, './eaglergrab', 'versions', 'dev.html'))
copyFile(path.join(__dirname, 'binaries', "arch.html"), path.join(homeDirectory, './eaglergrab', 'versions', 'arch.html'))
copyFile(path.join(__dirname, 'binaries', "settings.js"), path.join(homeDirectory, './eaglergrab', 'versions', 'settings.js'))

ipcMain.handle("start", () => {
win.loadFile(path.join(homeDirectory, "./eaglergrab", "versions", "latest.html"))
Expand Down

0 comments on commit 5437701

Please sign in to comment.