diff --git a/COMPATIBILITY_MATRIX.md b/COMPATIBILITY_MATRIX.md new file mode 100644 index 0000000..84a0ebe --- /dev/null +++ b/COMPATIBILITY_MATRIX.md @@ -0,0 +1,19 @@ +# Compatibility Matrix + +Target support window: `1.16.5` through `1.21.11`. + +| Minecraft version | Module | Status | +| --- | --- | --- | +| 1.16.5 | `fabric-1.16.5` | Implemented (full logic) | +| 1.17.1 | `fabric-1.17.1` | Build-ready port starter | +| 1.18.2 | `fabric-1.18.2` | Build-ready port starter | +| 1.19.4 | `fabric-1.19.4` | Build-ready port starter | +| 1.20.1 | `fabric-1.20.1` | Build-ready port starter | +| 1.21.1 | `fabric-1.21.1` | Build-ready port starter | +| 1.21.10 | `fabric-1.21.10` | Build-ready port starter | +| 1.21.11 | `fabric-1.21.11` | Build-ready port starter | + +Notes: +- Shared cryptographic and seed conversion code is centralized in `common`. +- World seed is enforced at exactly 1024 bits. +- Version-specific worldgen mixins still need per-version migration to reach full runtime parity with 1.16.5 behavior. diff --git a/README.md b/README.md index 9ee5184..3b005b9 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,16 @@ State-of-the-art cryptography to protect your world seed against seed cracking t This mod is written for the Fabric Mod Loader. If you have advanced knowledge on coding Spigot plugins, help with porting this to Spigot would be greatly appreciated. +## Project layout +- `common`: shared code that does not depend on a specific Minecraft version (hashing, seed constants, seed parsing utilities, shared interfaces). +- `fabric-1.16.5`: current working Fabric implementation for Minecraft 1.16.5. +- `fabric-1.21.10`: Loom-based port start for Minecraft 1.21.10 with shared seed logic already wired. + +Security baseline: +- World seed size is currently 1024 bits. +- A runtime guard enforces exactly 1024 bits. +- Supported version range is codified in `common` as `1.16.5` through `1.21.10`. + ## How does it work? 1. Increased the number of bits in the world seed from 64 to 1024. Although cracking a 64-bit seed with the other anti-seed-cracking measures is likely infeasible at the moment without access to a huge datacenter, we cannot rule out this possibility from the future, 1024 bits is likely to be safe for a *very* long time. 1. Changed the random number generators from LCGs (and the homebrew RNG in the biome generator) to a fast cryptographically secure RNG based on the [BLAKE2](https://en.wikipedia.org/wiki/BLAKE_(hash_function)) secure hashing algorithm. This has a minor negative impact on performance of world gen, but ensures that players cannot derive any information about the world other than the blocks they can already see. diff --git a/build.gradle b/build.gradle index b72d4f1..229eb38 100644 --- a/build.gradle +++ b/build.gradle @@ -1,75 +1,112 @@ plugins { - id 'fabric-loom' version '0.6-SNAPSHOT' - id 'maven-publish' + id 'base' + id 'fabric-loom' version '1.15.5' apply false } -sourceCompatibility = JavaVersion.VERSION_1_8 -targetCompatibility = JavaVersion.VERSION_1_8 +allprojects { + group = project.maven_group + version = project.mod_version -archivesBaseName = project.archives_base_name -version = project.mod_version -group = project.maven_group + repositories { + mavenCentral() + maven { + name = 'Fabric' + url = 'https://maven.fabricmc.net/' + } + } +} -dependencies { - //to change the versions see the gradle.properties file - minecraft "com.mojang:minecraft:${project.minecraft_version}" - mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2" - modImplementation "net.fabricmc:fabric-loader:${project.loader_version}" +subprojects { + apply plugin: 'maven-publish' + tasks.withType(JavaCompile).configureEach { + options.encoding = "UTF-8" + } - // PSA: Some older mods, compiled on Loom 0.2.1, might have outdated Maven POMs. - // You may need to force-disable transitiveness on them. -} + if (project.name.startsWith("fabric-")) { + apply plugin: 'fabric-loom' -processResources { - inputs.property "version", project.version + def mcVersion = project.name.substring(7) + def propSuffix = mcVersion.replace('.', '_') - from(sourceSets.main.resources.srcDirs) { - include "fabric.mod.json" - expand "version": project.version - } + def yarnMappings = rootProject.property("yarn_mappings_${propSuffix}") + def loaderVersion = rootProject.property("loader_version_${propSuffix}") + def javaRelease = rootProject.hasProperty("java_release_${propSuffix}") ? rootProject.property("java_release_${propSuffix}") as int : 8 - from(sourceSets.main.resources.srcDirs) { - exclude "fabric.mod.json" - } -} + java { + toolchain { + languageVersion = JavaLanguageVersion.of(rootProject.java_version as int) + } + withSourcesJar() + } -// ensure that the encoding is set to UTF-8, no matter what the system default is -// this fixes some edge cases with special characters not displaying correctly -// see http://yodaconditions.net/blog/fix-for-java-file-encoding-problems-with-gradle.html -tasks.withType(JavaCompile) { - options.encoding = "UTF-8" -} + tasks.withType(JavaCompile).configureEach { + options.release = javaRelease + } -// Loom will automatically attach sourcesJar to a RemapSourcesJar task and to the "build" task -// if it is present. -// If you remove this task, sources will not be generated. -task sourcesJar(type: Jar, dependsOn: classes) { - classifier = "sources" - from sourceSets.main.allSource -} + base { + archivesName = "${rootProject.archives_base_name}-mc${mcVersion}" + } -jar { - from "LICENSE" -} + dependencies { + implementation project(':common') -// configure the maven publication -publishing { - publications { - mavenJava(MavenPublication) { - // add all the jars that should be included when publishing to maven - artifact(remapJar) { - builtBy remapJar + minecraft "com.mojang:minecraft:${mcVersion}" + mappings "net.fabricmc:yarn:${yarnMappings}:v2" + modImplementation "net.fabricmc:fabric-loader:${loaderVersion}" + } + + processResources { + inputs.property "version", project.version + filesMatching("fabric.mod.json") { + expand "version": project.version } - artifact(sourcesJar) { - builtBy remapSourcesJar + } + + jar { + from "${rootProject.projectDir}/LICENSE" + } + + publishing { + publications { + mavenJava(MavenPublication) { + artifact(remapJar) { + builtBy remapJar + } + artifact(tasks.named('sourcesJar')) { + builtBy tasks.named('sourcesJar') + } + } } } + } else if (project.name == "common") { + apply plugin: 'java-library' + + java { + toolchain { + languageVersion = JavaLanguageVersion.of(rootProject.java_version as int) + } + } + + tasks.withType(JavaCompile).configureEach { + options.release = 8 + } + + jar { + archiveBaseName = "${rootProject.archives_base_name}-common" + } } +} - // select the repositories you want to publish to - repositories { - // uncomment to publish to the local maven - // mavenLocal() +tasks.register("compatibilityMatrix") { + group = "help" + description = "Prints SecureSeed compatibility status for 1.16.5-1.21.10" + doLast { + println("1.16.5 -> implemented (fabric-1.16.5)") + println("1.17.x -> planned migration track") + println("1.18.x -> planned migration track") + println("1.19.x -> planned migration track") + println("1.20.x -> planned migration track") + println("1.21.10 -> port started (fabric-1.21.10)") } } diff --git a/src/main/java/net/earthcomputer/secureseed/Hashing.java b/common/src/main/java/net/earthcomputer/secureseed/Hashing.java similarity index 87% rename from src/main/java/net/earthcomputer/secureseed/Hashing.java rename to common/src/main/java/net/earthcomputer/secureseed/Hashing.java index 51e0358..27bc3a0 100644 --- a/src/main/java/net/earthcomputer/secureseed/Hashing.java +++ b/common/src/main/java/net/earthcomputer/secureseed/Hashing.java @@ -28,14 +28,23 @@ public class Hashing { public static long[] hashWorldSeed(long[] worldSeed) { long[] result = blake2b_IV.clone(); result[0] ^= 0x01010040; + if (worldSeed.length != SeedConstants.WORLD_SEED_LONGS) { + throw new IllegalArgumentException("worldSeed must have length " + SeedConstants.WORLD_SEED_LONGS); + } hash(worldSeed, result, new long[16], 0, false); return result; } public static void hash(long[] message, long[] chainValue, long[] internalState, long messageOffset, boolean isFinal) { - assert message.length == 16; - assert chainValue.length == 8; - assert internalState.length == 16; + if (message.length != 16) { + throw new IllegalArgumentException("message must have length 16"); + } + if (chainValue.length != 8) { + throw new IllegalArgumentException("chainValue must have length 8"); + } + if (internalState.length != 16) { + throw new IllegalArgumentException("internalState must have length 16"); + } System.arraycopy(chainValue, 0, internalState, 0, chainValue.length); System.arraycopy(blake2b_IV, 0, internalState, chainValue.length, 4); diff --git a/src/main/java/net/earthcomputer/secureseed/IChunkRandom.java b/common/src/main/java/net/earthcomputer/secureseed/IChunkRandom.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/IChunkRandom.java rename to common/src/main/java/net/earthcomputer/secureseed/IChunkRandom.java diff --git a/src/main/java/net/earthcomputer/secureseed/IGeneratorOptions.java b/common/src/main/java/net/earthcomputer/secureseed/IGeneratorOptions.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/IGeneratorOptions.java rename to common/src/main/java/net/earthcomputer/secureseed/IGeneratorOptions.java diff --git a/src/main/java/net/earthcomputer/secureseed/IMoreOptionsDialog.java b/common/src/main/java/net/earthcomputer/secureseed/IMoreOptionsDialog.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/IMoreOptionsDialog.java rename to common/src/main/java/net/earthcomputer/secureseed/IMoreOptionsDialog.java diff --git a/src/main/java/net/earthcomputer/secureseed/IWorldChunk.java b/common/src/main/java/net/earthcomputer/secureseed/IWorldChunk.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/IWorldChunk.java rename to common/src/main/java/net/earthcomputer/secureseed/IWorldChunk.java diff --git a/common/src/main/java/net/earthcomputer/secureseed/MinecraftVersionSupport.java b/common/src/main/java/net/earthcomputer/secureseed/MinecraftVersionSupport.java new file mode 100644 index 0000000..c2e8ac2 --- /dev/null +++ b/common/src/main/java/net/earthcomputer/secureseed/MinecraftVersionSupport.java @@ -0,0 +1,33 @@ +package net.earthcomputer.secureseed; + +public final class MinecraftVersionSupport { + private MinecraftVersionSupport() { + } + + public static final String MIN_SUPPORTED = "1.16.5"; + public static final String MAX_SUPPORTED = "1.21.10"; + + public static boolean isWithinSupportedRange(String version) { + return compare(version, MIN_SUPPORTED) >= 0 && compare(version, MAX_SUPPORTED) <= 0; + } + + private static int compare(String left, String right) { + int[] l = parse(left); + int[] r = parse(right); + for (int i = 0; i < 3; i++) { + if (l[i] != r[i]) { + return Integer.compare(l[i], r[i]); + } + } + return 0; + } + + private static int[] parse(String version) { + String[] parts = version.split("\\."); + int[] parsed = new int[] {0, 0, 0}; + for (int i = 0; i < parsed.length && i < parts.length; i++) { + parsed[i] = Integer.parseInt(parts[i]); + } + return parsed; + } +} diff --git a/common/src/main/java/net/earthcomputer/secureseed/SeedConstants.java b/common/src/main/java/net/earthcomputer/secureseed/SeedConstants.java new file mode 100644 index 0000000..03391ee --- /dev/null +++ b/common/src/main/java/net/earthcomputer/secureseed/SeedConstants.java @@ -0,0 +1,16 @@ +package net.earthcomputer.secureseed; + +public final class SeedConstants { + private SeedConstants() { + } + + public static final int WORLD_SEED_LONGS = 16; + public static final int WORLD_SEED_BITS = WORLD_SEED_LONGS * 64; + public static final int REQUIRED_WORLD_SEED_BITS = 1024; + + static { + if (WORLD_SEED_BITS != REQUIRED_WORLD_SEED_BITS) { + throw new IllegalStateException("WORLD_SEED_BITS must be exactly " + REQUIRED_WORLD_SEED_BITS); + } + } +} diff --git a/common/src/main/java/net/earthcomputer/secureseed/SeedUtils.java b/common/src/main/java/net/earthcomputer/secureseed/SeedUtils.java new file mode 100644 index 0000000..d10210a --- /dev/null +++ b/common/src/main/java/net/earthcomputer/secureseed/SeedUtils.java @@ -0,0 +1,48 @@ +package net.earthcomputer.secureseed; + +import java.math.BigInteger; +import java.security.SecureRandom; + +public final class SeedUtils { + private SeedUtils() { + } + + public static long[] createRandomWorldSeed() { + long[] seed = new long[SeedConstants.WORLD_SEED_LONGS]; + SecureRandom rand = new SecureRandom(); + for (int i = 0; i < SeedConstants.WORLD_SEED_LONGS; i++) { + seed[i] = rand.nextLong(); + } + return seed; + } + + public static long[] parseSeed(String seedStr) { + long[] seed = new long[SeedConstants.WORLD_SEED_LONGS]; + try { + BigInteger seedBigInt = new BigInteger(seedStr); + if (seedBigInt.signum() < 0) { + seedBigInt = seedBigInt.and(BigInteger.ONE.shiftLeft(SeedConstants.WORLD_SEED_BITS).subtract(BigInteger.ONE)); + } + for (int i = 0; i < SeedConstants.WORLD_SEED_LONGS; i++) { + BigInteger[] divRem = seedBigInt.divideAndRemainder(BigInteger.ONE.shiftLeft(64)); + seed[i] = divRem[1].longValue(); + seedBigInt = divRem[0]; + } + } catch (NumberFormatException e) { + seed[0] = seedStr.hashCode(); + } + return seed; + } + + public static String seedToString(long[] seed) { + BigInteger seedBigInt = BigInteger.ZERO; + for (int i = SeedConstants.WORLD_SEED_LONGS - 1; i >= 0; i--) { + BigInteger val = BigInteger.valueOf(seed[i]); + if (val.signum() < 0) { + val = val.add(BigInteger.ONE.shiftLeft(64)); + } + seedBigInt = seedBigInt.shiftLeft(64).add(val); + } + return seedBigInt.toString(); + } +} diff --git a/src/main/java/net/earthcomputer/secureseed/Globals.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/Globals.java similarity index 60% rename from src/main/java/net/earthcomputer/secureseed/Globals.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/Globals.java index 6c0109c..5c0abf4 100644 --- a/src/main/java/net/earthcomputer/secureseed/Globals.java +++ b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/Globals.java @@ -3,12 +3,10 @@ import com.google.common.collect.Iterables; import net.minecraft.server.world.ServerWorld; -import java.math.BigInteger; -import java.security.SecureRandom; - public class Globals { - public static final int WORLD_SEED_LONGS = 16; - public static final int WORLD_SEED_BITS = WORLD_SEED_LONGS * 64; + public static final int WORLD_SEED_LONGS = SeedConstants.WORLD_SEED_LONGS; + public static final int WORLD_SEED_BITS = SeedConstants.WORLD_SEED_BITS; + public static final int REQUIRED_WORLD_SEED_BITS = SeedConstants.REQUIRED_WORLD_SEED_BITS; public static final long[] worldSeed = new long[WORLD_SEED_LONGS]; public static final ThreadLocal dimension = ThreadLocal.withInitial(() -> 0); @@ -45,43 +43,14 @@ public static void setupGlobals(ServerWorld world) { } public static long[] createRandomWorldSeed() { - long[] seed = new long[WORLD_SEED_LONGS]; - SecureRandom rand = new SecureRandom(); - for (int i = 0; i < WORLD_SEED_LONGS; i++) { - seed[i] = rand.nextLong(); - } - return seed; + return SeedUtils.createRandomWorldSeed(); } public static long[] parseSeed(String seedStr) { - long[] seed = new long[WORLD_SEED_LONGS]; - try { - BigInteger seedBigInt = new BigInteger(seedStr); - if (seedBigInt.signum() < 0) { - seedBigInt = seedBigInt.and(BigInteger.ONE.shiftLeft(WORLD_SEED_BITS).subtract(BigInteger.ONE)); - } - for (int i = 0; i < WORLD_SEED_LONGS; i++) { - BigInteger[] divRem = seedBigInt.divideAndRemainder(BigInteger.ONE.shiftLeft(64)); - seed[i] = divRem[1].longValue(); - seedBigInt = divRem[0]; - } - } catch (NumberFormatException e) { - seed[0] = seedStr.hashCode(); - } - - return seed; + return SeedUtils.parseSeed(seedStr); } public static String seedToString(long[] seed) { - BigInteger seedBigInt = BigInteger.ZERO; - for (int i = WORLD_SEED_LONGS - 1; i >= 0; i--) { - BigInteger val = BigInteger.valueOf(seed[i]); - if (val.signum() < 0) { - val = val.add(BigInteger.ONE.shiftLeft(64)); - } - seedBigInt = seedBigInt.shiftLeft(64).add(val); - } - - return seedBigInt.toString(); + return SeedUtils.seedToString(seed); } } diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/GeneratorOptionsAccessor.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/GeneratorOptionsAccessor.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/GeneratorOptionsAccessor.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/GeneratorOptionsAccessor.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinAbstractNetherSurfaceBuilder.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinAbstractNetherSurfaceBuilder.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinAbstractNetherSurfaceBuilder.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinAbstractNetherSurfaceBuilder.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinBadlandsSurfaceBuilder.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinBadlandsSurfaceBuilder.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinBadlandsSurfaceBuilder.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinBadlandsSurfaceBuilder.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinBiome.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinBiome.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinBiome.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinBiome.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinCachingLayerContext.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinCachingLayerContext.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinCachingLayerContext.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinCachingLayerContext.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinCarver.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinCarver.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinCarver.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinCarver.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinCaveCarver.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinCaveCarver.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinCaveCarver.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinCaveCarver.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkGenerator.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkGenerator.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkGenerator.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkGenerator.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkRandom.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkRandom.java similarity index 88% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkRandom.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkRandom.java index 5a3983b..3732b42 100644 --- a/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkRandom.java +++ b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkRandom.java @@ -3,7 +3,6 @@ import net.earthcomputer.secureseed.Globals; import net.earthcomputer.secureseed.Hashing; import net.earthcomputer.secureseed.IChunkRandom; -import net.minecraft.util.math.MathHelper; import net.minecraft.world.gen.ChunkRandom; import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.Overwrite; @@ -66,8 +65,8 @@ private void moreRandomBits() { public void secureseed_setSeed(long[] worldSeed, int x, int z, int dimension, int typeSalt, long salt) { System.arraycopy(worldSeed, 0, this.worldSeed, 0, Globals.WORLD_SEED_LONGS); message[0] = ((long) x << 32) | ((long) z & 0xffffffffL); - message[1] = ((long) dimension << 32) | ((long) salt & 0xffffffffL); - message[2] = typeSalt; + message[1] = ((long) dimension << 32) | ((long) typeSalt & 0xffffffffL); + message[2] = salt; message[3] = counter = 0; randomBitIndex = MAX_RANDOM_BIT_INDEX; secureSeeded = true; @@ -85,6 +84,12 @@ public void secureseed_setInsecure() { @Unique private long getBits(int count) { + if (count < 0 || count > 64) { + throw new IllegalArgumentException("count must be in [0, 64], got " + count); + } + if (count == 0) { + return 0; + } if (!secureSeeded) { throw new IllegalStateException("Using unseeded ChunkRandom"); } @@ -96,21 +101,18 @@ private long getBits(int count) { int alignment = randomBitIndex & 63; if ((randomBitIndex >>> 6) == ((randomBitIndex + count) >>> 6)) { - long result = (randomBits[randomBitIndex >>> 6] >>> alignment) & ((1L << count) - 1); + long result = randomBits[randomBitIndex >>> 6] >>> alignment; + if (count != 64) { + result &= (1L << count) - 1; + } randomBitIndex += count; return result; } else { - long result = (randomBits[randomBitIndex >>> 6] >>> alignment) & ((1L << (64 - alignment)) - 1); - randomBitIndex += count; - if (randomBitIndex >= MAX_RANDOM_BIT_INDEX) { - moreRandomBits(); - randomBitIndex -= MAX_RANDOM_BIT_INDEX; - } - alignment = randomBitIndex & 63; - result <<= alignment; - result |= (randomBits[randomBitIndex >>> 6] >>> (64 - alignment)) & ((1L << alignment) - 1); - - return result; + int lowerCount = 64 - alignment; + long lower = randomBits[randomBitIndex >>> 6] >>> alignment; + randomBitIndex += lowerCount; + long upper = getBits(count - lowerCount); + return lower | (upper << lowerCount); } } @@ -148,11 +150,14 @@ public void consume(int count) { @Override public int nextInt(int bound) { if (!secure) return super.nextInt(bound); + if (bound <= 0) { + throw new IllegalArgumentException("bound must be positive"); + } - int bits = MathHelper.log2DeBruijn(bound); + int bits = 32 - Integer.numberOfLeadingZeros(bound - 1); int result; do { - result = (int) getBits(bits); + result = bits == 0 ? 0 : (int) getBits(bits); } while (result >= bound); return result; diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkStatus.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkStatus.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkStatus.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinChunkStatus.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinCreateWorldScreen.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinCreateWorldScreen.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinCreateWorldScreen.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinCreateWorldScreen.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinEndBiomeSource.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinEndBiomeSource.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinEndBiomeSource.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinEndBiomeSource.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinEndSpikeFeature.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinEndSpikeFeature.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinEndSpikeFeature.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinEndSpikeFeature.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinEnderDragonFight.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinEnderDragonFight.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinEnderDragonFight.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinEnderDragonFight.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinGeneratorOptions.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinGeneratorOptions.java similarity index 94% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinGeneratorOptions.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinGeneratorOptions.java index b8a0216..ade6594 100644 --- a/src/main/java/net/earthcomputer/secureseed/mixin/MixinGeneratorOptions.java +++ b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinGeneratorOptions.java @@ -35,12 +35,12 @@ public class MixinGeneratorOptions implements IGeneratorOptions { @Override public long[] secureseed_getSeed() { - return secureSeed; + return secureSeed == null ? null : secureSeed.clone(); } @Override public void secureseed_setSeed(long[] seed) { - this.secureSeed = seed; + this.secureSeed = seed == null ? null : seed.clone(); if (seed != null) this.seed = seed[0]; } @@ -81,7 +81,7 @@ private static App ci) { String seedStr = properties.getProperty("level-seed"); - long[] seed = seedStr.isEmpty() ? Globals.createRandomWorldSeed() : Globals.parseSeed(seedStr); + long[] seed = seedStr == null || seedStr.isEmpty() ? Globals.createRandomWorldSeed() : Globals.parseSeed(seedStr); ((IGeneratorOptions) ci.getReturnValue()).secureseed_setSeed(seed); } } diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinMinecraftServer.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinMinecraftServer.java similarity index 100% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinMinecraftServer.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinMinecraftServer.java diff --git a/src/main/java/net/earthcomputer/secureseed/mixin/MixinMoreOptionsDialog.java b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinMoreOptionsDialog.java similarity index 97% rename from src/main/java/net/earthcomputer/secureseed/mixin/MixinMoreOptionsDialog.java rename to fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinMoreOptionsDialog.java index 918abfc..c863740 100644 --- a/src/main/java/net/earthcomputer/secureseed/mixin/MixinMoreOptionsDialog.java +++ b/fabric-1.16.5/src/main/java/net/earthcomputer/secureseed/mixin/MixinMoreOptionsDialog.java @@ -57,6 +57,6 @@ private void setSecureSeedOnGeneratorOptions(CallbackInfoReturnable=0.11.1" + } +} diff --git a/fabric-1.17.1/src/main/resources/secureseed-1.17.1.mixins.json b/fabric-1.17.1/src/main/resources/secureseed-1.17.1.mixins.json new file mode 100644 index 0000000..ef0df29 --- /dev/null +++ b/fabric-1.17.1/src/main/resources/secureseed-1.17.1.mixins.json @@ -0,0 +1,11 @@ +{ + "required": false, + "minVersion": "0.8", + "package": "net.earthcomputer.secureseed.mixin", + "compatibilityLevel": "JAVA_8", + "mixins": [], + "client": [], + "injectors": { + "defaultRequire": 1 + } +} diff --git a/fabric-1.18.2/src/main/java/net/earthcomputer/secureseed/PortStart.java b/fabric-1.18.2/src/main/java/net/earthcomputer/secureseed/PortStart.java new file mode 100644 index 0000000..284ab9a --- /dev/null +++ b/fabric-1.18.2/src/main/java/net/earthcomputer/secureseed/PortStart.java @@ -0,0 +1,14 @@ +package net.earthcomputer.secureseed; + +public final class PortStart { + private PortStart() { + } + + public static long[] createPortSeed() { + return SeedUtils.createRandomWorldSeed(); + } + + public static int requiredSeedBits() { + return SeedConstants.REQUIRED_WORLD_SEED_BITS; + } +} diff --git a/fabric-1.18.2/src/main/resources/assets/secureseed/icon.png b/fabric-1.18.2/src/main/resources/assets/secureseed/icon.png new file mode 100644 index 0000000..8b58a65 Binary files /dev/null and b/fabric-1.18.2/src/main/resources/assets/secureseed/icon.png differ diff --git a/fabric-1.18.2/src/main/resources/fabric.mod.json b/fabric-1.18.2/src/main/resources/fabric.mod.json new file mode 100644 index 0000000..636b137 --- /dev/null +++ b/fabric-1.18.2/src/main/resources/fabric.mod.json @@ -0,0 +1,24 @@ +{ + "schemaVersion": 1, + "id": "secureseed", + "version": "${version}", + "name": "SecureSeed", + "description": "State-of-the-art cryptography to protect your world seed against seed cracking tools", + "authors": [ + "Earthcomputer" + ], + "contact": { + "website": "https://earthcomputer.net", + "repo": "https://github.com/Earthcomputer/SecureSeed" + }, + "license": "MIT", + "icon": "assets/secureseed/icon.png", + "environment": "*", + "entrypoints": {}, + "mixins": [ + "secureseed-1.18.2.mixins.json" + ], + "depends": { + "fabricloader": ">=0.11.1" + } +} diff --git a/fabric-1.18.2/src/main/resources/secureseed-1.18.2.mixins.json b/fabric-1.18.2/src/main/resources/secureseed-1.18.2.mixins.json new file mode 100644 index 0000000..ef0df29 --- /dev/null +++ b/fabric-1.18.2/src/main/resources/secureseed-1.18.2.mixins.json @@ -0,0 +1,11 @@ +{ + "required": false, + "minVersion": "0.8", + "package": "net.earthcomputer.secureseed.mixin", + "compatibilityLevel": "JAVA_8", + "mixins": [], + "client": [], + "injectors": { + "defaultRequire": 1 + } +} diff --git a/fabric-1.19.4/src/main/java/net/earthcomputer/secureseed/PortStart.java b/fabric-1.19.4/src/main/java/net/earthcomputer/secureseed/PortStart.java new file mode 100644 index 0000000..284ab9a --- /dev/null +++ b/fabric-1.19.4/src/main/java/net/earthcomputer/secureseed/PortStart.java @@ -0,0 +1,14 @@ +package net.earthcomputer.secureseed; + +public final class PortStart { + private PortStart() { + } + + public static long[] createPortSeed() { + return SeedUtils.createRandomWorldSeed(); + } + + public static int requiredSeedBits() { + return SeedConstants.REQUIRED_WORLD_SEED_BITS; + } +} diff --git a/fabric-1.19.4/src/main/resources/assets/secureseed/icon.png b/fabric-1.19.4/src/main/resources/assets/secureseed/icon.png new file mode 100644 index 0000000..8b58a65 Binary files /dev/null and b/fabric-1.19.4/src/main/resources/assets/secureseed/icon.png differ diff --git a/fabric-1.19.4/src/main/resources/fabric.mod.json b/fabric-1.19.4/src/main/resources/fabric.mod.json new file mode 100644 index 0000000..42089de --- /dev/null +++ b/fabric-1.19.4/src/main/resources/fabric.mod.json @@ -0,0 +1,24 @@ +{ + "schemaVersion": 1, + "id": "secureseed", + "version": "${version}", + "name": "SecureSeed", + "description": "State-of-the-art cryptography to protect your world seed against seed cracking tools", + "authors": [ + "Earthcomputer" + ], + "contact": { + "website": "https://earthcomputer.net", + "repo": "https://github.com/Earthcomputer/SecureSeed" + }, + "license": "MIT", + "icon": "assets/secureseed/icon.png", + "environment": "*", + "entrypoints": {}, + "mixins": [ + "secureseed-1.19.4.mixins.json" + ], + "depends": { + "fabricloader": ">=0.11.1" + } +} diff --git a/fabric-1.19.4/src/main/resources/secureseed-1.19.4.mixins.json b/fabric-1.19.4/src/main/resources/secureseed-1.19.4.mixins.json new file mode 100644 index 0000000..ef0df29 --- /dev/null +++ b/fabric-1.19.4/src/main/resources/secureseed-1.19.4.mixins.json @@ -0,0 +1,11 @@ +{ + "required": false, + "minVersion": "0.8", + "package": "net.earthcomputer.secureseed.mixin", + "compatibilityLevel": "JAVA_8", + "mixins": [], + "client": [], + "injectors": { + "defaultRequire": 1 + } +} diff --git a/fabric-1.20.1/src/main/java/net/earthcomputer/secureseed/PortStart.java b/fabric-1.20.1/src/main/java/net/earthcomputer/secureseed/PortStart.java new file mode 100644 index 0000000..284ab9a --- /dev/null +++ b/fabric-1.20.1/src/main/java/net/earthcomputer/secureseed/PortStart.java @@ -0,0 +1,14 @@ +package net.earthcomputer.secureseed; + +public final class PortStart { + private PortStart() { + } + + public static long[] createPortSeed() { + return SeedUtils.createRandomWorldSeed(); + } + + public static int requiredSeedBits() { + return SeedConstants.REQUIRED_WORLD_SEED_BITS; + } +} diff --git a/fabric-1.20.1/src/main/resources/assets/secureseed/icon.png b/fabric-1.20.1/src/main/resources/assets/secureseed/icon.png new file mode 100644 index 0000000..8b58a65 Binary files /dev/null and b/fabric-1.20.1/src/main/resources/assets/secureseed/icon.png differ diff --git a/fabric-1.20.1/src/main/resources/fabric.mod.json b/fabric-1.20.1/src/main/resources/fabric.mod.json new file mode 100644 index 0000000..3011b7a --- /dev/null +++ b/fabric-1.20.1/src/main/resources/fabric.mod.json @@ -0,0 +1,24 @@ +{ + "schemaVersion": 1, + "id": "secureseed", + "version": "${version}", + "name": "SecureSeed", + "description": "State-of-the-art cryptography to protect your world seed against seed cracking tools", + "authors": [ + "Earthcomputer" + ], + "contact": { + "website": "https://earthcomputer.net", + "repo": "https://github.com/Earthcomputer/SecureSeed" + }, + "license": "MIT", + "icon": "assets/secureseed/icon.png", + "environment": "*", + "entrypoints": {}, + "mixins": [ + "secureseed-1.20.1.mixins.json" + ], + "depends": { + "fabricloader": ">=0.11.1" + } +} diff --git a/fabric-1.20.1/src/main/resources/secureseed-1.20.1.mixins.json b/fabric-1.20.1/src/main/resources/secureseed-1.20.1.mixins.json new file mode 100644 index 0000000..ef0df29 --- /dev/null +++ b/fabric-1.20.1/src/main/resources/secureseed-1.20.1.mixins.json @@ -0,0 +1,11 @@ +{ + "required": false, + "minVersion": "0.8", + "package": "net.earthcomputer.secureseed.mixin", + "compatibilityLevel": "JAVA_8", + "mixins": [], + "client": [], + "injectors": { + "defaultRequire": 1 + } +} diff --git a/fabric-1.21.1/src/main/java/net/earthcomputer/secureseed/PortStart.java b/fabric-1.21.1/src/main/java/net/earthcomputer/secureseed/PortStart.java new file mode 100644 index 0000000..284ab9a --- /dev/null +++ b/fabric-1.21.1/src/main/java/net/earthcomputer/secureseed/PortStart.java @@ -0,0 +1,14 @@ +package net.earthcomputer.secureseed; + +public final class PortStart { + private PortStart() { + } + + public static long[] createPortSeed() { + return SeedUtils.createRandomWorldSeed(); + } + + public static int requiredSeedBits() { + return SeedConstants.REQUIRED_WORLD_SEED_BITS; + } +} diff --git a/fabric-1.21.1/src/main/resources/assets/secureseed/icon.png b/fabric-1.21.1/src/main/resources/assets/secureseed/icon.png new file mode 100644 index 0000000..8b58a65 Binary files /dev/null and b/fabric-1.21.1/src/main/resources/assets/secureseed/icon.png differ diff --git a/fabric-1.21.1/src/main/resources/fabric.mod.json b/fabric-1.21.1/src/main/resources/fabric.mod.json new file mode 100644 index 0000000..d646cfa --- /dev/null +++ b/fabric-1.21.1/src/main/resources/fabric.mod.json @@ -0,0 +1,24 @@ +{ + "schemaVersion": 1, + "id": "secureseed", + "version": "${version}", + "name": "SecureSeed", + "description": "State-of-the-art cryptography to protect your world seed against seed cracking tools", + "authors": [ + "Earthcomputer" + ], + "contact": { + "website": "https://earthcomputer.net", + "repo": "https://github.com/Earthcomputer/SecureSeed" + }, + "license": "MIT", + "icon": "assets/secureseed/icon.png", + "environment": "*", + "entrypoints": {}, + "mixins": [ + "secureseed-1.21.1.mixins.json" + ], + "depends": { + "fabricloader": ">=0.11.1" + } +} diff --git a/fabric-1.21.1/src/main/resources/secureseed-1.21.1.mixins.json b/fabric-1.21.1/src/main/resources/secureseed-1.21.1.mixins.json new file mode 100644 index 0000000..ef0df29 --- /dev/null +++ b/fabric-1.21.1/src/main/resources/secureseed-1.21.1.mixins.json @@ -0,0 +1,11 @@ +{ + "required": false, + "minVersion": "0.8", + "package": "net.earthcomputer.secureseed.mixin", + "compatibilityLevel": "JAVA_8", + "mixins": [], + "client": [], + "injectors": { + "defaultRequire": 1 + } +} diff --git a/fabric-1.21.10/README.md b/fabric-1.21.10/README.md new file mode 100644 index 0000000..66d6edb --- /dev/null +++ b/fabric-1.21.10/README.md @@ -0,0 +1,7 @@ +# fabric-1.21.10 +This module is the migration target for Minecraft 1.21.10. + +Current status: +- Dedicated Loom module is configured. +- Shared seed utilities from `common` are wired. +- Version-specific mixins and mappings from `fabric-1.16.5` still need to be ported. diff --git a/fabric-1.21.10/src/main/java/net/earthcomputer/secureseed/PortStart.java b/fabric-1.21.10/src/main/java/net/earthcomputer/secureseed/PortStart.java new file mode 100644 index 0000000..284ab9a --- /dev/null +++ b/fabric-1.21.10/src/main/java/net/earthcomputer/secureseed/PortStart.java @@ -0,0 +1,14 @@ +package net.earthcomputer.secureseed; + +public final class PortStart { + private PortStart() { + } + + public static long[] createPortSeed() { + return SeedUtils.createRandomWorldSeed(); + } + + public static int requiredSeedBits() { + return SeedConstants.REQUIRED_WORLD_SEED_BITS; + } +} diff --git a/fabric-1.21.10/src/main/resources/assets/secureseed/icon.png b/fabric-1.21.10/src/main/resources/assets/secureseed/icon.png new file mode 100644 index 0000000..8b58a65 Binary files /dev/null and b/fabric-1.21.10/src/main/resources/assets/secureseed/icon.png differ diff --git a/fabric-1.21.10/src/main/resources/fabric.mod.json b/fabric-1.21.10/src/main/resources/fabric.mod.json new file mode 100644 index 0000000..b6ecbf1 --- /dev/null +++ b/fabric-1.21.10/src/main/resources/fabric.mod.json @@ -0,0 +1,24 @@ +{ + "schemaVersion": 1, + "id": "secureseed", + "version": "${version}", + "name": "SecureSeed", + "description": "State-of-the-art cryptography to protect your world seed against seed cracking tools", + "authors": [ + "Earthcomputer" + ], + "contact": { + "website": "https://earthcomputer.net", + "repo": "https://github.com/Earthcomputer/SecureSeed" + }, + "license": "MIT", + "icon": "assets/secureseed/icon.png", + "environment": "*", + "entrypoints": {}, + "mixins": [ + "secureseed-1.21.10.mixins.json" + ], + "depends": { + "fabricloader": ">=0.11.1" + } +} diff --git a/fabric-1.21.10/src/main/resources/secureseed-1.21.10.mixins.json b/fabric-1.21.10/src/main/resources/secureseed-1.21.10.mixins.json new file mode 100644 index 0000000..ef0df29 --- /dev/null +++ b/fabric-1.21.10/src/main/resources/secureseed-1.21.10.mixins.json @@ -0,0 +1,11 @@ +{ + "required": false, + "minVersion": "0.8", + "package": "net.earthcomputer.secureseed.mixin", + "compatibilityLevel": "JAVA_8", + "mixins": [], + "client": [], + "injectors": { + "defaultRequire": 1 + } +} diff --git a/fabric-1.21.11/src/main/java/net/earthcomputer/secureseed/PortStart.java b/fabric-1.21.11/src/main/java/net/earthcomputer/secureseed/PortStart.java new file mode 100644 index 0000000..284ab9a --- /dev/null +++ b/fabric-1.21.11/src/main/java/net/earthcomputer/secureseed/PortStart.java @@ -0,0 +1,14 @@ +package net.earthcomputer.secureseed; + +public final class PortStart { + private PortStart() { + } + + public static long[] createPortSeed() { + return SeedUtils.createRandomWorldSeed(); + } + + public static int requiredSeedBits() { + return SeedConstants.REQUIRED_WORLD_SEED_BITS; + } +} diff --git a/fabric-1.21.11/src/main/resources/assets/secureseed/icon.png b/fabric-1.21.11/src/main/resources/assets/secureseed/icon.png new file mode 100644 index 0000000..8b58a65 Binary files /dev/null and b/fabric-1.21.11/src/main/resources/assets/secureseed/icon.png differ diff --git a/fabric-1.21.11/src/main/resources/fabric.mod.json b/fabric-1.21.11/src/main/resources/fabric.mod.json new file mode 100644 index 0000000..9353d7e --- /dev/null +++ b/fabric-1.21.11/src/main/resources/fabric.mod.json @@ -0,0 +1,24 @@ +{ + "schemaVersion": 1, + "id": "secureseed", + "version": "${version}", + "name": "SecureSeed", + "description": "State-of-the-art cryptography to protect your world seed against seed cracking tools", + "authors": [ + "Earthcomputer" + ], + "contact": { + "website": "https://earthcomputer.net", + "repo": "https://github.com/Earthcomputer/SecureSeed" + }, + "license": "MIT", + "icon": "assets/secureseed/icon.png", + "environment": "*", + "entrypoints": {}, + "mixins": [ + "secureseed-1.21.11.mixins.json" + ], + "depends": { + "fabricloader": ">=0.11.1" + } +} diff --git a/fabric-1.21.11/src/main/resources/secureseed-1.21.11.mixins.json b/fabric-1.21.11/src/main/resources/secureseed-1.21.11.mixins.json new file mode 100644 index 0000000..ef0df29 --- /dev/null +++ b/fabric-1.21.11/src/main/resources/secureseed-1.21.11.mixins.json @@ -0,0 +1,11 @@ +{ + "required": false, + "minVersion": "0.8", + "package": "net.earthcomputer.secureseed.mixin", + "compatibilityLevel": "JAVA_8", + "mixins": [], + "client": [], + "injectors": { + "defaultRequire": 1 + } +} diff --git a/gradle.properties b/gradle.properties index 9d6138b..9629205 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,12 +1,51 @@ # Done to increase the memory available to gradle. org.gradle.jvmargs=-Xmx1G -# Fabric Properties -# check these on https://modmuss50.me/fabric.html -minecraft_version=1.16.5 -yarn_mappings=1.16.5+build.4 -loader_version=0.11.1 +java_version=21 +# Fabric 1.16.5 Properties +loom_version_1_16_5=1.15.5 +minecraft_version_1_16_5=1.16.5 +yarn_mappings_1_16_5=1.16.5+build.4 +loader_version_1_16_5=0.11.1 + +# Fabric 1.21.10 target (port start) +loom_version_1_21_10=1.15.5 +minecraft_version_1_21_10=1.21.10 +yarn_mappings_1_21_10=1.21.10+build.3 +loader_version_1_21_10=0.19.1 + # Mod Properties mod_version=0.1 maven_group=net.earthcomputer archives_base_name=secureseed +loom_version_1_17_1=1.15.5 +minecraft_version_1_17_1=1.17.1 +yarn_mappings_1_17_1=1.17.1+build.65 +loader_version_1_17_1=0.19.1 +java_release_1_17_1=16 +loom_version_1_18_2=1.15.5 +minecraft_version_1_18_2=1.18.2 +yarn_mappings_1_18_2=1.18.2+build.4 +loader_version_1_18_2=0.19.1 +java_release_1_18_2=17 +loom_version_1_19_4=1.15.5 +minecraft_version_1_19_4=1.19.4 +yarn_mappings_1_19_4=1.19.4+build.2 +loader_version_1_19_4=0.19.1 +java_release_1_19_4=17 +loom_version_1_20_1=1.15.5 +minecraft_version_1_20_1=1.20.1 +yarn_mappings_1_20_1=1.20.1+build.10 +loader_version_1_20_1=0.19.1 +java_release_1_20_1=17 +loom_version_1_21_1=1.15.5 +minecraft_version_1_21_1=1.21.1 +yarn_mappings_1_21_1=1.21.1+build.3 +loader_version_1_21_1=0.19.1 +java_release_1_21_1=21 +java_release_1_21_10=21 +loom_version_1_21_11=1.15.5 +minecraft_version_1_21_11=1.21.11 +yarn_mappings_1_21_11=1.21.11+build.4 +loader_version_1_21_11=0.19.1 +java_release_1_21_11=21 diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index bb8b2fc..63e0e83 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.5.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.0-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/settings.gradle b/settings.gradle index 5b60df3..1035597 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1,6 +1,6 @@ pluginManagement { repositories { - jcenter() + mavenCentral() maven { name = 'Fabric' url = 'https://maven.fabricmc.net/' @@ -8,3 +8,15 @@ pluginManagement { gradlePluginPortal() } } + +rootProject.name = 'SecureSeed' + +include 'common' +include 'fabric-1.16.5' +include 'fabric-1.17.1' +include 'fabric-1.18.2' +include 'fabric-1.19.4' +include 'fabric-1.20.1' +include 'fabric-1.21.1' +include 'fabric-1.21.10' +include 'fabric-1.21.11'