diff --git a/build.gradle b/build.gradle index 59e7abd..034cb38 100644 --- a/build.gradle +++ b/build.gradle @@ -23,7 +23,7 @@ dependencies mappings loom.layered() { officialMojangMappings() - parchment("org.parchmentmc.data:parchment-${project.minecraft_version}:${project.mappings_version}@zip") + parchment("org.parchmentmc.data:parchment-${project.mappings_version}@zip") } modImplementation "net.fabricmc:fabric-loader:${project.loader_version}" diff --git a/gradle.properties b/gradle.properties index 63d39f9..cd2b10b 100644 --- a/gradle.properties +++ b/gradle.properties @@ -5,9 +5,9 @@ org.gradle.parallel=true # Fabric Properties # https://fabricmc.net/develop # https://parchmentmc.org/docs/getting-started - minecraft_version=1.20.6 + minecraft_version=1.21 loader_version=0.15.11 - mappings_version=2024.05.01 + mappings_version=1.20.6:2024.06.02 # Mod Properties mod_version=1.1 @@ -15,4 +15,4 @@ org.gradle.parallel=true archives_base_name=IronDoorKey # Dependencies - fabric_version=0.99.0+1.20.6 + fabric_version=0.100.1+1.21 diff --git a/src/main/java/com/mt1006/irondoorkey/IronDoorKeyMod.java b/src/main/java/com/mt1006/irondoorkey/IronDoorKeyMod.java index 5aa3a4c..43a7141 100644 --- a/src/main/java/com/mt1006/irondoorkey/IronDoorKeyMod.java +++ b/src/main/java/com/mt1006/irondoorkey/IronDoorKeyMod.java @@ -17,17 +17,17 @@ public class IronDoorKeyMod implements ModInitializer { public static final String MOD_ID = "irondoorkey"; public static final String VERSION = "1.1"; - public static final String FOR_VERSION = "1.20.6"; + public static final String FOR_VERSION = "1.21"; public static final String FOR_LOADER = "Fabric"; public static final Logger LOGGER = LogUtils.getLogger(); public static final Item ITEM_IRON_DOOR_KEY = new IronDoorKeyItem(); - public static final TagKey OPENABLE = TagKey.create(Registries.BLOCK, new ResourceLocation(MOD_ID, "openable")); + public static final TagKey OPENABLE = TagKey.create(Registries.BLOCK, ResourceLocation.fromNamespaceAndPath(MOD_ID, "openable")); @Override public void onInitialize() { LOGGER.info("{} - Author: mt1006", getFullName()); - Registry.register(BuiltInRegistries.ITEM, new ResourceLocation(MOD_ID, "iron_door_key"), ITEM_IRON_DOOR_KEY); + Registry.register(BuiltInRegistries.ITEM, ResourceLocation.fromNamespaceAndPath(MOD_ID, "iron_door_key"), ITEM_IRON_DOOR_KEY); ItemGroupEvents.modifyEntriesEvent(CreativeModeTabs.TOOLS_AND_UTILITIES) .register(content -> content.accept(ITEM_IRON_DOOR_KEY)); diff --git a/src/main/resources/data/irondoorkey/recipes/iron_door_key.json b/src/main/resources/data/irondoorkey/recipe/iron_door_key.json similarity index 100% rename from src/main/resources/data/irondoorkey/recipes/iron_door_key.json rename to src/main/resources/data/irondoorkey/recipe/iron_door_key.json diff --git a/src/main/resources/data/irondoorkey/tags/blocks/openable.json b/src/main/resources/data/irondoorkey/tags/block/openable.json similarity index 100% rename from src/main/resources/data/irondoorkey/tags/blocks/openable.json rename to src/main/resources/data/irondoorkey/tags/block/openable.json diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index 5b96ab3..482db7a 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -24,7 +24,7 @@ "depends": { - "minecraft": "~1.20.5", + "minecraft": ">=1.21", "fabricloader": ">=0.15.0", "fabric-api": "*", "java": ">=21"