Pierce01 / MinecraftLauncher-core

Lightweight module that downloads and runs Minecraft using javascript / NodeJS
MIT License
359 stars 82 forks source link

When I re-launch minecraft, forge does not load. #59

Closed Zlatex closed 3 years ago

Zlatex commented 3 years ago

When I re-launch minecraft, forge does not load. I am using vue-cli-plugin-electron-builder. If I restart the application the forge is loaded. MCLC v. 3.16.1 forge v. 14.23.5.2854

Zlatex commented 3 years ago
import { Client, Authenticator } from 'minecraft-launcher-core';
var launcher;
launcher = new Client();

launcher.on('data',(d)=>{
    console.log(d);
})
launcher.on('debug',(d)=>{
    console.log(d);
})
let opts = {
    root: "path",
    authorization: Authenticator.getAuth("username"),
    version: {
        number: "1.12.2",
        type: "release"
    },
    forge: "path/to/forge",
    memory: {
        max: "5000",
        min: "1000"
    }
} 
function launch(){
    launcher.launch(opts);
}

When I run the launch function again, then forge is not loaded. Only if I run it for the first time or restart the application.

Pierce01 commented 3 years ago

Thats weird.. I'm unable to repro this. Is your launcher uploaded anywhere? I'll try looking into this when I can.

Zlatex commented 3 years ago

https://github.com/Zlatex/tmp src/electron/components/startMinecraft.js

Pierce01 commented 3 years ago

Sorry for taking so long, your issue has been fixed in the following commit: 449e15e