Quickstart
Quickstart
Use the Stonecraft template
The simplest way to get started with a brand new mod project is to use the Stonecraft template.
Simply go to https://github.com/meza/Stonecraft-template and click the "Use this template" button.
Add the plugin to build.gradle[.kts]
If you already use Architectury, make sure to add Stonecraft BEFORE the Architectury plugin.
// build.gradle.kts
plugins {
id("gg.meza.stonecraft")
}
Set up Stonecutter
Setting up supported version
Create a settings.gradle[.kts] file in your project root with the following content:
This is still boilerplate, and I'm working on making it more user-friendly.
pluginManagement {
repositories {
mavenCentral()
gradlePluginPortal()
maven("https://maven.kikugie.dev/releases")
maven("https://maven.kikugie.dev/snapshots")
maven("https://maven.fabricmc.net/")
maven("https://maven.architectury.dev")
maven("https://maven.minecraftforge.net")
maven("https://maven.neoforged.net/releases/")
}
}
plugins {
id("gg.meza.stonecraft") version "1.9.+"
id("dev.kikugie.stonecutter") version "0.8+"
}
stonecutter {
centralScript = "build.gradle.kts"
kotlinController = true
shared {
fun mc(version: String, vararg loaders: String) {
// Make the relevant version directories named "1.20.2-fabric", "1.20.2-forge", etc.
for (it in loaders) vers("$version-$it", version)
}
mc("1.21.3", "fabric", "forge", "neoforge")
mc("1.21.4", "fabric", "forge", "neoforge")
}
create(rootProject)
}
rootProject.name = "YourModName"
Creating your dependency files
In order to manage different dependencies for different versions of Minecraft, you need to create a separate file for each version.
These need to be placed in the versions/dependencies directory.
versions/dependencies/1.21.3.propertiesversions/dependencies/1.21.4.properties
These would be the equivalent of the more traditional gradle.properties file for each version.
The name of the files is important. These needs to be the same as the versions you specified in the settings.gradle.kts file.
Setting up the stonecutter
Create a stonecutter.gradle[.kts] file in your project root with the following content:
// stonecutter.gradle.kts
plugins {
id("dev.kikugie.stonecutter")
id("gg.meza.stonecraft")
}
stonecutter active "1.21.4-fabric" /* [SC] DO NOT EDIT */
Stonecutter 0.8 keeps the native Gradle task fan-out introduced in 0.7 while layering the typed task APIs and parser/handler rewrite. Stonecraft wires the typed accessors for you, so you can stick with the stock Gradle tasks (build, publishMods, etc.) or keep using the chiseled* wrappers if your CI expects them. For background on why the native tasks are preferred, see our blog post.