summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorshartte <shartte@users.noreply.github.com>2024-06-13 23:32:54 +0200
committerGitHub <noreply@github.com>2024-06-13 23:32:54 +0200
commit6b865f6fd0bd171ea2dc280086b93f0a2e289ba6 (patch)
tree54c34b775be9a77883be59e6edd2de179a1c0ce6
parentf515fca9aff757dc7bd8ea87d68fc1a92c390bb4 (diff)
Update to 1.21 (#71)
-rw-r--r--gradle.properties10
-rw-r--r--src/main/java/com/example/examplemod/Config.java4
2 files changed, 7 insertions, 7 deletions
diff --git a/gradle.properties b/gradle.properties
index 9144e9a..82bac1a 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -10,17 +10,17 @@ neogradle.subsystems.parchment.mappingsVersion=2024.05.01
# Environment Properties
# You can find the latest versions here: https://projects.neoforged.net/neoforged/neoforge
# The Minecraft version must agree with the Neo version to get a valid artifact
-minecraft_version=1.20.6
+minecraft_version=1.21
# The Minecraft version range can use any release version of Minecraft as bounds.
# Snapshots, pre-releases, and release candidates are not guaranteed to sort properly
# as they do not follow standard versioning conventions.
-minecraft_version_range=[1.20.6,1.21)
+minecraft_version_range=[1.21,1.21.1)
# The Neo version must agree with the Minecraft version to get a valid artifact
-neo_version=20.6.112-beta
+neo_version=21.0.0-beta
# The Neo version range can use any version of Neo as bounds
-neo_version_range=[20.6,)
+neo_version_range=[21.0.0-beta,)
# The loader version range can only use the major version of FML as bounds
-loader_version_range=[2,)
+loader_version_range=[4,)
## Mod Properties
diff --git a/src/main/java/com/example/examplemod/Config.java b/src/main/java/com/example/examplemod/Config.java
index 7f5aa8b..d70d1eb 100644
--- a/src/main/java/com/example/examplemod/Config.java
+++ b/src/main/java/com/example/examplemod/Config.java
@@ -45,7 +45,7 @@ public class Config
private static boolean validateItemName(final Object obj)
{
- return obj instanceof String itemName && BuiltInRegistries.ITEM.containsKey(new ResourceLocation(itemName));
+ return obj instanceof String itemName && BuiltInRegistries.ITEM.containsKey(ResourceLocation.parse(itemName));
}
@SubscribeEvent
@@ -57,7 +57,7 @@ public class Config
// convert the list of strings into a set of items
items = ITEM_STRINGS.get().stream()
- .map(itemName -> BuiltInRegistries.ITEM.get(new ResourceLocation(itemName)))
+ .map(itemName -> BuiltInRegistries.ITEM.get(ResourceLocation.parse(itemName)))
.collect(Collectors.toSet());
}
}