Please make sure to make your pull requests off the main
branch if you're adding new features.
If there's an important bug fix, always make a PR, but off of the stable
branch. Then that hotfix
can be rebased back into main
afterwards (with checkout main
, & rebase stable
).
# Not recommended
git checkout -b development --track origin/development
- JDK (You need both)
- JDK 8
- JDK 17
- IDE (One of them)
- IntelliJ IDEA (Recommended)
- Our team uses IDEA. We may not be able to provide support for other IDEs.
- Eclipse
- IntelliJ IDEA (Recommended)
- (Plugin) Lombok to help with things such as not having to manually create Getters and Setters.
- IntelliJ IDEA (pre-installed)
- Eclipse
Note: You can use gradle
instead of using gradle wrapper ./gradlew
.
- Clone the repository
- Wait for the gradle project to import.
- Setup the development environment
./gradlew setupDecompWorkspace
- Integrate the development environment with your IDE
- IntelliJ IDEA
- Set the project SDK to Java 8 (instructions)
- Set the gradle JVM to 17 (instructions)
- Eclipse (doesn't generate debug configuration)
./gradlew eclipse
- Change Text File Encoding from
Default
toUTF-8
- Go to
Window
->Preferences
->General
->Workspace
- Change
Text File Encoding
fromDefault
toUTF-8
- Go to
- IntelliJ IDEA
- You are now ready to build the mod!
- Build the mod
./gradlew build
Notes
If your jar build is failing because the code is trying to access private methods or fields, this may be because someone added some new access transformers.
You may want to re-run the gradle task
./gradlew setupDecompWorkspace
so the access transformers are applied to the source code!
The build process produces three artifacts:
- SkyblockAddons-1.7.2.jar (mod code and resources)
- SkyblockAddons-1.7.2-all.jar (above + shaded libraries)
- SkyblockAddons-1.7.2-for-MC-1.8.9.jar (above + remapped for obfuscated environment)
- (Optional) Run the Minecraft Forge client
- Using IntelliJ IDEA
- Add the environment variable
FETCH_DATA_ONLINE=true
if you want to use data files from the CDN. - Run the "Minecraft Client" debug configuration.
- Click the link in the console to log in with DevAuth.
- Add the environment variable
- Using the command line
./gradlew runClient --args="--username <username> --password <password>"
- Using IntelliJ IDEA