Setting up Modding Environment (Eclipse) - Jacob1225/pufferfish-minecraft-mod GitHub Wiki
Note: Steps shown were done on Windows 10. Setup on other operating systems may differ. This installation guide is for Forge 1.16.5 - 36.2.20. It uses Java JDK 1.8u311 and Eclipse IDE 4.16. If errors occur, check if you have other versions of Java JDK installed (they may conflict). Perform a clean installation of all software.
Step 1: Install Java JDK
- Minecraft 1.16.x runs on Java JDK 1.8. Download and install jdk-8u311. (Default installation is acceptable)
- Need to set path to JDK 1.8. Start Menu > (Search) Edit the system environment variables > Advanced > Environment Variables... > Select the variable called 'Path' under the System variables table > Edit... > New > (Type file location of installed JDK 1.8) C:\Program Files\Java\jdk1.8.0_311\bin > OK
Step 2: Install Eclipse IDE
- Download and install Eclipse 2020-06 (4.16). Select 'Eclipse IDE for Java Developers'. (Default installation is acceptable, accept any unsigned files)
Make sure the selected JDK matches the one we installed in Step 1:
Step 3: Download mod project folder
- See GitHub repository for the latest mod version, download the main in ZIP format on your machine.
Un-zip the folder in your work directory and import the project [Step 4]
- Or preferably clone the repository by Eclipse, and then open it as a project. The following steps demonstrate the process in detail:
- Copy the repository in your clipboard.
- On the Eclipse under Git repository tab, select "Clone a Git Repository"
The repository info will be populated in the opened window, you would need to add your Github user name and password and press NEXT
Eclipse will choose a default git location under your user account to clone the repository, if no change needed press Finish.
It will take some time to clone a local copy on your machine.
Step 4: Build mod with Gradle
- Launch Eclipse and select a workspace or use the default.
- Select File > Import... > Gradle > Existing Gradle Project > Next > Browse... > (Find the mod directory) .../pufferfish-minecraft-mod/teamPufferFish > Finish The project folder may take some time to import.
- Click on the Gradle Tasks tab and navigate to teamPufferFish > fg_runs > genEclipseRuns (Double-click to execute)
What a successful build should look like:
- Go back to the Gradle Tasks tab and navigate to teamPufferFish > ide > eclipse (Double-click to execute)
What a successful build should look like:
Step 5: Run mod
- In the Gradle Tasks, navigate to teamPufferFish > fg_runs > runClient (Double-click to execute) to launch Minecraft Forge 1.12.x with mods. ENJOY!