Also how do turn .jar into .class? In shell
- .class files are java bytecode, not java source code
- if you mean how to turn a .jar into folders with .java files, first what decompiler are you using: vineflower, retromcp-java, or another?
Iām trying to use the jar command
you can't decompile jars with the jar
command
Then how?
jar command wont work i have java installed
i keep getting cant find symbol gl11
if you're compiling it, then it's because you're not putting the lwjgl jar in the classpath
Where do I get lwjgl jar and where do I put it?
i'm not exactly sure but wherever minecraft gets it from
wherever in your filesystem you want really because in the command to compile java files, you reference things in setting the classpath by path
i cant find where to get the jar
found the jar next i just need to know how to do stuff with it like do i put it in a folder called org? and like i downloaded the same version of minecraft you were modding so i was wondering if i could see a screen shot of your folder in which the stuff is in
i have it in multiple folders but i'll make a dummy folder rq
Edit: (i'm not taking these screenshots again so imagine the lwjgl natives jar is in the folder too)
then to decompile use vineflower
/path/to/rd/folder/ $ java17 -jar vineflower.jar "minecraft rd jar.jar"
(the 17 is because vineflower needs java 17--everything else uses java 8, though i think you might be able to use java 17 if you add a couple extra arguments)
then you should have something like this:
then edit the sources in the minecraft rd jar
folder, then to compile it again, first use javac
/path/to/rd/folder/ $ javac8 -d mcmodout "minecraft rd jar/**/*.java"
then you should have this
then run
/path/to/rd/folder/ $ jar -cvf modded.jar -C mcmodout/ .
and to run the jar, do
/path/to/rd/folder/ $ java8 -Djava.library.path=lwjgl-natives.jar -cp lwjgl.jar:lwjgl-util.jar:modded.jar org.mojang.rubydung.Rubydung
(i might have gotten something in that wrong but the general structure is there)
thx
in the forums can you send files? like the lwjgl and lwjgl util and also im new to java so what is a class path? also i im gpnna put my files inside org folder and inside that is lwjgl and then inside im gonna put lwjgl.jar and other also what about natives?
i'll try to find official downloads for them
that's unnecessary but if you do you have to change the references to those files in the java command
right i forgot about those--i'll edit my post for that
lwjgl utils doesnt exist anymore you cant find it
here are lwjgl jar downloads:
https://repo.papermc.io/repository/maven-public/org/lwjgl/lwjgl/lwjgl/2.9.4-nightly-20150209/lwjgl-2.9.4-nightly-20150209.jar
https://repo.papermc.io/repository/maven-public/org/lwjgl/lwjgl/lwjgl_util/2.9.4-nightly-20150209/lwjgl_util-2.9.4-nightly-20150209.jar
natives for windows: https://repo.papermc.io/repository/maven-public/org/lwjgl/lwjgl/lwjgl-platform/2.9.4-nightly-20150209/lwjgl-platform-2.9.4-nightly-20150209-natives-windows.jar
natives for linux: https://repo.papermc.io/repository/maven-public/org/lwjgl/lwjgl/lwjgl-platform/2.9.4-nightly-20150209/lwjgl-platform-2.9.4-nightly-20150209-natives-linux.jar
natives for mac osx: https://repo.papermc.io/repository/maven-public/org/lwjgl/lwjgl/lwjgl-platform/2.9.4-nightly-20150209/lwjgl-platform-2.9.4-nightly-20150209-natives-osx.jar
they aren't on lwjgl's servers but they are on papermc's servers so i'm fairly certain they are correct
does rd mc have a ddefault class path? cuz im kinda lazy i dont wanna go through each and every file and change the class path