mirror of
https://github.com/artegoser/pimi-launcher-core.git
synced 2024-12-23 10:23:47 +03:00
Merge pull request #6 from MelonCode/master
Added option to specify JRE executable file
This commit is contained in:
commit
d523d6563c
2 changed files with 2 additions and 1 deletions
|
@ -40,6 +40,7 @@ launcher.authenticator.getAuth("email", "password").then(auth => {
|
|||
| `options.clientPackage` | String | Path to the client package zip file. | False |
|
||||
| `options.root` | String | Path where you want the launcher to work in. like `C:/Users/user/AppData/Roaming/.mc` | True |
|
||||
| `options.os` | String | windows, osx or linux | True |
|
||||
| `options.javaPath` | String | Path to the JRE executable file, will default to `java` if not entered. | False |
|
||||
| `options.version.number` | String | Minecraft version that is going to be launched. | True |
|
||||
| `options.version.type` | String | Any string. The actual Minecraft launcher uses `release` and `snapshot`. | True |
|
||||
| `options.memory.max` | String | Max amount of memory being used by Minectaft | True |
|
||||
|
|
|
@ -61,7 +61,7 @@ module.exports = async function (options) {
|
|||
|
||||
const launchArguments = args.concat(jvm, classPaths, launchOptions);
|
||||
|
||||
const minecraft = child.spawn(`java`, launchArguments);
|
||||
const minecraft = child.spawn(options.javaPath ? options.javaPath : 'java', launchArguments);
|
||||
event.emit('start', null);
|
||||
minecraft.stdout.on('data', (data) => event.emit('data', data));
|
||||
minecraft.stderr.on('data', (data) => event.emit('error', data));
|
||||
|
|
Loading…
Add table
Reference in a new issue