0

I am building a server in MC and I managed to change the plugin the way I wanted and now I want to compile that changed .java file to get the .class file and run the plugin on my server. However, I can't figure out how to recompile that specific .java file to generate the new .class file. Does anyone have any suggestions?

My process:

  1. Get the .jar of the plugin and change it to .zip to get the src of the jar

  2. Decompile the class I want to edit, copy the code into a new .java file and delete the .class

  3. (Where I fail) Recompile the .java file to generate the .class

  4. zip the folder and change it to .jar

Lukyan
  • 91
  • 5

1 Answers1

0

I don't know if this will help you, but here's how I do it:

  1. Open the plugin in JD-GUI (Yes, you'll need to download it)
  2. File>Save Source, Resource or whatever.
  3. It will be saved as Winrar from what I remember, what you're going to want to do is extract that folder into your Eclipse workspace folder.
  4. Create a new java project, and name the project whatever the folder you extracted was called.
  5. It should say there is already a .project or whatever and you'll just want to click finish.
  6. Change things around and add dependencies.