1

I am rather stumped on how to do this.

I have come across a python module to launch minecraft from a command line or wrather generate a command...

import minecraft_launcher_lib
import subprocess
import sys

lv = "1.8.9-forge-11.15.1.2318"
md = "C:\\Users\\*****\\AppData\\Roaming\\.minecraft"
options = {
    "username": "rohwn",
    "uuid": "5a848c091a5f476ab94b4d09af4613cc",
    "token": "{Insert token here}"
}
minecraft_command = minecraft_launcher_lib.command.get_minecraft_command(lv, md, options)
subprocess.call(minecraft_command)

This code works for versions of minecraft and forge > 1.12 but not for 1.12 and 1.8.9 I cannot seem to figure out why. I have also thought of using the minecraft launcher enter image description here

By changing the "Java Executable" to an exe that logs the arguments and runs minecraft but I cannot seem to do this nor have the expertise. (If someone could provide some code or something that could do that, that would be great!)

I have also seen commands that other people have created but still dont work for me. E.x

Launch Minecraft from command line - username and password as prefix

If someone could help me launch minecraft forge 1.8.9 from command line that would be great! Thanks (in advance)

Mofi
  • 46,139
  • 17
  • 80
  • 143
Joe Jameson
  • 79
  • 1
  • 12
  • can you add error logs to the question. What error is thrown when you try to run that specific version, also can you list contents of `.minecraft/versions` folder. – Sharmiko Jul 08 '22 at 13:15
  • I'm the author of minecraft-launcher-lib. Could you please post the output of Minecraft after running the command, so I can help you. – JakobDev Jul 12 '22 at 12:38

0 Answers0