mindstorm38 / portablemc

A fast, reliable and cross-platform command-line Minecraft launcher and API for developers. Including fast and easy installation of common mod loaders such as Fabric, Forge, NeoForge and Quilt.
https://pypi.org/project/portablemc/
GNU General Public License v3.0
354 stars 20 forks source link

LWJGL not found in classpath for early versions #185

Open CodeUnderscoreRocker opened 11 months ago

CodeUnderscoreRocker commented 11 months ago

I put this command in the terminal: python3.11 -m portablemc start a1.1.0 And received a message in the terminal that LWGL couldn't be found! As the launcher normal takes care of the java classpath, I would think this is a bug. I also manually tried adding lwjgl to the classpath env variable to no avail.

Here is the output of that command (with private info taken out):

[  OK  ] Resolved version a1.1.0.
[  OK  ] Loaded version JAR.
[  OK  ] Checked 749 assets.
[  OK  ] Loaded logger.
[  OK  ] Loaded 11 libraries.
[  OK  ] Loaded Mojang Java 8u74.
Oct 27, 2023 12:17:14 PM net.minecraft.launchwrapper.LogWrapper log
INFO: Using tweak class name net.minecraft.launchwrapper.VanillaTweaker
Oct 27, 2023 12:17:15 PM net.minecraft.launchwrapper.LogWrapper log
INFO: Launching wrapped minecraft
28
Turning of ImageIO disk-caching
Loading current icons for window from: /Users/*****************/Library/Application Support/minecraft/assets/virtual/pre-1.6/icons/icon_16x16.png and /Users/******************/Library/Application Support/minecraft/assets/virtual/pre-1.6/icons/icon_32x32.png
javax.imageio.IIOException: Can't read input file!
    at javax.imageio.ImageIO.read(ImageIO.java:1301)
    at net.minecraft.launchwrapper.injector.VanillaTweakInjector.loadIcon(VanillaTweakInjector.java:130)
    at net.minecraft.launchwrapper.injector.VanillaTweakInjector.loadIconsOnFrames(VanillaTweakInjector.java:107)
    at net.minecraft.launchwrapper.injector.VanillaTweakInjector.inject(VanillaTweakInjector.java:94)
    at net.minecraft.client.Minecraft.main(SourceFile:1375)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at net.minecraft.launchwrapper.Launch.launch(Launch.java:57)
    at net.minecraft.launchwrapper.Launch.main(Launch.java:18)
Setting gameDir to: /Users/*************************/Library/Application Support/minecraft
Exception in thread "Minecraft main thread" java.lang.UnsatisfiedLinkError: no lwjgl in java.library.path
    at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1864)
    at java.lang.Runtime.loadLibrary0(Runtime.java:870)
    at java.lang.System.loadLibrary(System.java:1122)
    at org.lwjgl.Sys$1.run(Sys.java:73)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.lwjgl.Sys.doLoadLibrary(Sys.java:66)
    at org.lwjgl.Sys.loadLibrary(Sys.java:95)
    at org.lwjgl.Sys.<clinit>(Sys.java:112)
    at org.lwjgl.opengl.Display.<clinit>(Display.java:135)
    at net.minecraft.client.Minecraft.a(SourceFile:148)
    at net.minecraft.client.Minecraft.run(SourceFile:554)
    at java.lang.Thread.run(Thread.java:745)
mindstorm38 commented 11 months ago

What is the launcher version (portablemc show about)? And on what operating system/architecture is that?

CodeUnderscoreRocker commented 11 months ago

What is the launcher version (portablemc show about)? And on what operating system/architecture is that?

It is on macOS Ventura 13.6 running on a mid-2017 iMac with a x86 Intel Core i5 processor.

CodeUnderscoreRocker commented 11 months ago

Here is the output of the show about command:

Version: 3.3.1 Authors: Théo Rozier contact@theorozier.fr, Github contributors Website: https://github.com/mindstorm38/portablemc License: PortableMC Copyright (C) 2021-2023 Théo Rozier This program comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. See https://www.gnu.org/licenses/gpl-3.0.html.

CodeUnderscoreRocker commented 11 months ago

I'll update my copy and try again.

CodeUnderscoreRocker commented 11 months ago

Still doesn't work due to the same error. (I updated to 4.0.3)

mindstorm38 commented 11 months ago

Perfect, thank you for the details! I wonder if macOS is supported in these older LWJGL release, I'll check this

mindstorm38 commented 11 months ago

Can you tell me which files are present in the .minecraft/bin/<UUID>/ directory that is created? It might also be useful to have the verbose output activated on the launcher (-vv argument).