tutorial:setup
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
tutorial:setup [2019/11/16 19:14] – fix another curse fudge | tutorial:setup [2021/09/17 14:46] – some tweaks siglong | ||
---|---|---|---|
Line 2: | Line 2: | ||
===== Prerequisites ===== | ===== Prerequisites ===== | ||
+ | * A Java Development Kit (JDK) for Java 16 (recommended) or newer. Visit [[https:// | ||
+ | * If you are professional, | ||
+ | * Any Java IDE, for example [[https:// | ||
+ | * If you are not familiar with any of these, we recommend to use Intellij IDEA as that is what most people choose for modding. | ||
- | * A Java Development | + | ==== Minecraft |
- | * Any IDE, for example | + | If you are using IntelliJ IDEA you can use the [[https://plugins.jetbrains.com/ |
+ | This plugin adds support for automatically generating Fabric projects as well as some mixin related features like inspections, | ||
+ | generating accessors/ | ||
+ | You can install it using IntelliJ' | ||
+ | then clicking the Marketplace tab and searching for Minecraft. | ||
- | ===== Steps ===== | + | ===== Mod Startup |
+ | There are two main ways to make a new mod for Minecraft based on Fabric. | ||
+ | You can either manually download fabric-example-mod and setup by yourself, or use automatic tools for you. | ||
- | - Copy the starting files from [[https:// | + | **NOTE:** The template in the mcdev plugin blindly uses the latest unstable version of the loom. Use with caution. |
+ | |||
+ | ==== Manual Steps ==== | ||
+ | - Copy the starting files from [[https:// | ||
- Edit '' | - Edit '' | ||
* Make sure to set '' | * Make sure to set '' | ||
- | * Make sure to update the versions of Minecraft, the mappings | + | * Make sure to update the versions of Minecraft, the mappings, the loader |
* Add any other dependencies you plan to use in '' | * Add any other dependencies you plan to use in '' | ||
- | - Import the build.gradle file to your IDE. Follow [[tutorial: | + | - Import the build.gradle file to your IDE. You may refer to the next section for specific |
- | - For IntelliJ, press '' | + | |
- Happy modding! | - Happy modding! | ||
- | You can generate the Minecraft sources for reference (since | + | If you are unable to use the mc plugin or the fabric-example-mod, |
- | Run the '' | + | - Download latest release of GeneratorFabricMod [[https:// |
+ | - Make a new directory, then run a command shell there and type '' | ||
+ | - After letting it get its dependencies, | ||
+ | - You're now done, just open the project folder with in your IDE. | ||
+ | |||
+ | === IntelliJ | ||
+ | If you are using IntelliJ IDEA by JetBrains, please follow these steps: | ||
+ | - In the IDEA main menu, select ' | ||
+ | - Select the project' | ||
+ | - After Gradle | ||
+ | - (If the run configurations still don't show up, try reimporting the Gradle project from the Gradle tab in IDEA.) | ||
+ | |||
+ | //Optional, but recommended// | ||
+ | By default, IntelliJ delegates to Gradle to build the project. This is unnecessary for Fabric and causes longer build times and hotswapping related weirdness, among other problems. To make it use the builtin compiler: | ||
+ | - Open the ' | ||
+ | - Change the 'Build and run using' and 'Run tests using' fields to ' | ||
+ | - Go to File -> Project Structure -> Project and set ' | ||
+ | |||
+ | Unfortunately, | ||
+ | |||
+ | **NOTE:** Don't run the '' | ||
+ | |||
+ | === Eclipse === | ||
+ | If you are using Eclipse and you would like to have the IDE run configs you can run '' | ||
+ | |||
+ | === Visual Studio Code === | ||
+ | If you are using VSCode, please follow [[tutorial: | ||
+ | |||
+ | ===== Generating Minecraft Sources ===== | ||
+ | Reading the Minecraft source is an essential part of modding. | ||
+ | Unfortunately, | ||
+ | You need to generate the Minecraft yourself. | ||
+ | |||
+ | To generate the Minecraft source. run the '' | ||
+ | If your IDE doesn' | ||
+ | It can take a while depends on your computer power. | ||
+ | You may need to refresh gradle after running the task. | ||
===== Getting started ===== | ===== Getting started ===== | ||
Try [[tutorial: | Try [[tutorial: | ||
- | ===== Advice ===== | ||
- | | + | ===== Advice ===== |
- | * As Fabric is in early development, | + | |
+ | * Occasionally, with development of fabric-loom (our Gradle build plugin) issues may crop up which require | ||
* Don't hesitate to ask questions! We're here to help you and work with you to make your dream mod a reality. | * Don't hesitate to ask questions! We're here to help you and work with you to make your dream mod a reality. | ||
Line 32: | Line 80: | ||
==== Missing sounds ==== | ==== Missing sounds ==== | ||
- | |||
Sometimes, when importing the Gradle project into an IDE, the assets might not download correctly. In this case, run the '' | Sometimes, when importing the Gradle project into an IDE, the assets might not download correctly. In this case, run the '' | ||
tutorial/setup.txt · Last modified: 2024/08/12 04:20 by jeffreyg1228